COnditional statements for blog/ static content
-
Just curious.. I have read a lot about how to write a conditional statement where a widget (or hard coded widget) will display only on certain pages.
I have a website that is run by wordpress but isn’t mainly a blog/ I would like it so that a few of my widgets only show when you are on the blog..
Now the blog page is called blog, but there are multiple pages, would this code still work?
<?php if (is_page(array('blog'))) { ;?> hardcoded widget here <?php } ?>
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘COnditional statements for blog/ static content’ is closed to new replies.