Postingan

Menampilkan postingan dari Juni, 2019

Blogger Conditional Tags for different page types

Gambar
Conditional template tags in Blogger template allows you to specify a part of your template code on specific types of pages or specific URLs. One practical application could be to display a widget on specific pages. You can hide sidebar on some pages, apply a meta tag to certain page or whatsoever. Complex Blogger templates make large use of these conditional tags. In this post, I'll show you the possible conditional tags and their example usage. A conditional template tag in Blogger looks like following <b: if cond= 'condition_expression' > <!-- content when condition is satisfied --> </ b:if > List of Conditional tags for page types Archive page <b: if cond= 'data:blog.pageType == "archive"' > <!--archive_Page--> </ b:if > Error Page (404) <b: if cond= 'data:blog.pageType == "error_page"' > <!-- all error pages--> </ b:if > Index Page <b: if cond= 'data:blog.page