Mensch Tracht und Gott Lacht - Filtering Views, News, Tips, Tricks and Temporal Anomalies

Main Page Sidebar Display Once

March 29, 2006 | In marketing, blogging |

How would someone display an ad only on the main page sidebar?

The Conditional Tags can be used in your Template files to change what content is displayed and how that content is displayed on a particular page depending on what conditions that page matches. For example, you might want to display a snippet of text above the series of posts, but only on the main page of your blog. With the is_home() Conditional Tag, that task is made easy.

< ?php if(is_home()) : ?>
~ad code here ~
< ?php endif; ?>

Bookmark this post at del.icio.us

No Comments yet »

RSS feed for comments on this post. TrackBack URI

Leave a comment

XHTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>

Powered by WordPress with Pool theme design by Borja Fernandez.
Entries and comments feeds. Valid XHTML and CSS. ^Top^