Breadcrumb navigation is a way to show links above your posts. It is useful in improving your blog’s navigation as it helps a user knows where he/she is in the navigation hierarchy. For example, a breadcrumb on your blog will look like the following:
Home > LabelStep 1: Sign in to your blog
Home > All posts under Label
Visit Google Blogspot home page at: http://blogspot.com/ orhttp://www.blogger.com/ and sign in with your Google account.
Step 2: Back up your blog template
- Choose Design / Edit HTML.
- Click "Download Full Template" to back up your blog template.
Step 3: Edit Template
- Tick on "Expand Widget Templates" in the Edit Templates tab
- Locate the following code in your blog template
<b:includable id='main' var='top'>Copy under
<b:if cond='data:mobile == "false"'>
<b:includable id='main' var='top'>the following codes:
<b:if cond='data:mobile == "false"'>
<b:if cond='data:blog.homepageUrl == data:blog.url'>
<!-- No breadcrumb navigation on home page -->
<b:else/>
<b:if cond='data:blog.pageType == "item"'>
<div class='breadcrumbs'>
<a expr:href='data:blog.homepageUrl' rel='tag'>Home</a>
<b:loop values='data:posts' var='post'>
<b:if cond='data:post.labels'>
<b:loop values='data:post.labels' var='label'>
<b:if cond='data:label.isLast == "true"'> »
<a expr:href='data:label.url' rel='tag'><data:label.name/></a>
</b:if>
</b:loop>
</b:if>
</b:loop>
</div>
</b:if>
<b:else/>
<b:if cond='data:blog.pageType == "archive"'>
<div class='breadcrumbs'>
Archives for <data:blog.pageName/>
</div>
</b:if>
<b:else/>
<b:if cond='data:blog.pageType == "index"'>
<!-- breadcrumb for the label page -->
<div class='breadcrumbs'>
<a expr:href='data:blog.homepageUrl'>Home</a> » All posts under <data:blog.pageName/>
</div>
</b:if>
</b:if>
Click "Save Template".
Step 4: Add Custom CSS for your breadcumbs
Add the following CSS codes to your blogger blog html template (click here) :
.breadcrumbs {
padding-bottom:5px;
padding-top:5px;
padding-right: 7px;
margin-bottom: 5px;
font-size: 105%;
line-height: opx;
border-bottom:1px double #e6e4e3;
border-top:1px double #e6e4e3;
}
No comments:
Post a Comment