The Syntax and Attribute
Blogger XML Language
<b:defaultmarkups> <b:defaultmarkup type='WIDGET_TYPE'> </b:defaultmarkup> </b:defaultmarkups>
Implementation and Example
This tag set can be placed anywhere except in the <b:skin> and <b:template-skin>. Example placing right before </head> or </body> or </html>. Placing it right before </body> seems like a good idea, its make it easier to find and manage it.When the widget / gadgets are installed or reset, the inclusions that are nested inside <b:defaultmarkup> will be automatically added inside the body of the widget, and, if the id of inclusion match with the current widget, it will be overridden by this markup.
Example: Single Widget Template Marking
<b:defaultmarkups> <b:defaultmarkup type='Blog'> <b:includable id='main'> <!-- Main code Block --> </b:includable> </b:defaultmarkup> </b:defaultmarkups>
Example: Marking Multiple Gadgets and Inclusion
<b:defaultmarkups> <b:defaultmarkup type='Blog,FeaturedPost,PopularPosts'> <b:includable id='postJumpLink'> <!-- postJumpLink code Block --> </b:includable> <b:includable id='postFooterJumpLink'> <!-- postFooterJumpLink code Block --> </b:includable> </b:defaultmarkup> </b:defaultmarkups>
We can also create an inclusions that can be called anywhere in the theme. by giving the type value 'Common' in a tag <b:defaultmarkup> and calling with singleton tag <b:include name='ID'/> instead of a type of markup.
Example: Common inclusions in a gadget
<b:defaultmarkups> <b:defaultmarkup type='Common'> <b:includable id='MyMetaTags'> <!-- "MyMetaTags" inclusion code block --> </b:includable> </b:defaultmarkup> </b:defaultmarkups>
Example: Calling Common inclusion
<b:widget> <b:include name='MyMetaTags'/> </b:widget>
In above example we creating an inclusion with id 'MyMetaTags', because its nested in <b:defaultmarkup> tag with type 'Common', so, we can call it anywhere with <b:include> tag with name value is id from <b:includable> tag.
Other Tag
- <b:attr>
- <b:case>
- <b:class>
- <b:comment>
- <b:default>
- <b:defaultmarkup>
- <b:defaultmarkups>
- <b:eval>
- <b:else>
- <b:elseif>
- <b:if>
- <b:include>
- <b:includable>
- <b:loop>
- <b:message>
- <b:param>
- <b:section>
- <b:skin>
- <b:switch>
- <b:tag>
- <b:template-script>
- <b:template-skin>
- <b:widget>
- <b:widget-setting>
- <b:widget-settings>
- <b:with>
- <![CDATA[]]>
- <data:.../>