Markup tags <b:defaultmarkups> is <b:defaultmarkup> nesting place, and if we nest <b:includable> inside this tag, we can create default theme layout to the template.

The Syntax and Attribute

Blogger XML Language
    <b:defaultmarkup type='WIDGET_TYPE'>
  • The tag <b:defaultmarkups> can only contain tags <b:defaultmarkup>.
  • Multiple <b:defaultmarkup> can be nested with different type.
  • The tag <b:defaultmarkup> can only contain tags <b:includable>.
  • The block <b:defaultmarkups> should preferably be located before </head> or </body>.

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:defaultmarkup type='Blog'>
        <b:includable id='main'>
            <!-- Main code Block -->
Example: Marking Multiple Gadgets and Inclusion
    <b:defaultmarkup type='Blog,FeaturedPost,PopularPosts'>
        <b:includable id='postJumpLink'>
            <!-- postJumpLink code Block -->
        <b:includable id='postFooterJumpLink'>
            <!-- postFooterJumpLink code Block -->

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:defaultmarkup type='Common'>
    <b:includable id='MyMetaTags'>
      <!-- "MyMetaTags" inclusion code block -->

Example: Calling Common inclusion
    <b:include name='MyMetaTags'/>

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

Share This

Creative Commons License
Blogger Book is licensed under a Creative Commons Attribution-NonCommercial 3.0 Unported License.