how to display the gadget sidebar on certain pages


how to display the gadget sidebar on certain pages
Here are the parts of your blog page 
Homepage - Is your blog's main page, the front page. 
Archivepage - is the archive page 
Itempage - Is your post pages 
Indexpage - It is the home page, the page labels, and search page. 
Staticpage-new feature that google page that does not get in on the posts. 


1. Showing Widget Only on Homepage 

<b:if cond='data:blog.url == data:blog.homepageUrl'>
..........................
</ B: if>


2. Widget displays in addition to the Homepage 

<b:if cond='data:blog.url != data:blog.homepageUrl'>
.....................................
</ B: if>

3. Widget displays only in Archivepages 


<b:if cond='data:blog.pageType == "archive"'>
......................................
</ B: if>


4. Widget displays in addition to the Archivepages 


<b:if cond='data:blog.pageType != "archive"'>
.................................................. ..
</ B: if>

5. Widget displays only in Itempages / Post 


<b:if cond='data:blog.pageType == "item"'>
............................................
</ B: if>

6. Displays widgets in addition to the Itempages 


<b:if cond='data:blog.pageType != "item"'>
....................................
</ B: if>

7. Displaying widgets only in Staticpages 


<b:if cond='data:blog.pageType == "static_page"'>
..................................
</ B: if>

8. Displays widgets in addition to the staticpages 


<b:if cond='data:blog.pageType != "static_page"'>
............................
</ B: if>

9. Posts widget displays the URL of Certain 


<b:if cond='data:blog.url == "your URL posts "'>
.........................................
</ B: if>

10. Displays widgets in addition to the specific post URL

<b:if cond='data:blog.url != "your URL posts"'>
................................................
</ B: if>

How Uses? 
The following code example my blog widget 
    <b:widget id='HTML2' locked='false' title='stat' article type='HTML'> 
    <b:includable id='main'> 
    .................................................. opening code 
      <! - Only display title if it's a non-empty -> 
      <b:if cond='data:title != ""'> 
        <h2 class='title'> <data:title/> </ h2> 
      </ B: if> 
      <div class='widget-content'> 
        <data:content/> 
      </ Div> 
      <b:include name='quickedit'/> 
    .............................................. cover code 
    </ B: includable> 
    </ B: widget> 


The red is the placement of code for the appearance of the widget on certain pages only. May be useful 

Labels: ,