Uncategorized
Oct27

>Widget in the Sidebar Only Show In HomePage

0 comment

>

1. Find Code Widget
– Login into blogger
– Layout
– Edit HTML
– Check Expand Widget Templates

Suppose my widget code my recent post was:


<b:widget id=’HTML1′ locked=’false’ title=” type=’HTML’>
<b:includable id=’main’>
<!– only display title if it’s non-empty –>
<b:if cond=’data:title != &quot;&quot;’>
<h2 class=’title’><data:title/></h2>
</b:if>
<div class=’widget-content’>
<data:content/>
</div>

<b:include name=’quickedit’/>
</b:includable>
</b:widget>

2. Add the code to be like this …

Now, change the code to be like this …

<b:widget id=’HTML1′ locked=’false’ title=” type=’HTML’>
<b:includable id=’main’>
<b:if cond=’data:blog.homepageUrl == data:blog.url’>

<!– only display title if it’s 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’/>

</b:if>

</b:includable>
</b:widget>

Note that red is the added ….
Good luck …

Author: 

author