Hello, does anyone know how I could get WordPress to not display some code on Pages, whilst displaying it on Posts? Specifically, I want the “Posted by *author* on *date* in *category*” bit to not appear on pages.
All I know for sure is that I’ll be using is_page to determine that a Page is loaded. Here’s the bit I want to be hidden on Pages:
<?php _e(“Posted on “); ?> <?php the_time(‘F jS, Y’) ?> in <?php the_category(‘,’) ?> by <?php the_author() ?> <?php edit_post_link(‘Edit’, ‘ | ‘, ”); ?>
I read the Codex page on Conditional Tags (http://codex.wordpress.org/Conditional_Tags) but after fiddling with the syntax examples given there, I just can’t seem to get it to work.
Can anyone help?
- The topic ‘is_page to display/not display some code’ is closed to new replies.