WordPress.org

Support

Support » Themes and Templates » Having trouble moving page name on the ‘blog’

Having trouble moving page name on the ‘blog’

  • Hi All,

    I’m trying to move the page name into the header of the web page.

    I’ve used <?php echo $post->post_title ?> which works fine for all ‘Pages’, but when it comes to the ‘News’ page (the actual blog – I’ve created an actual page named ‘News’ and Ive assigned it to be the ‘Posts Page’.) it displays the first title of the post, instead of ‘News’.

    I have tried creating a ‘custom field’ named page-title. But I can get anything to show up using get_post_meta( $post->ID , 'page-title' , true );

    Any help is appreciated.
    Thanks

Viewing 1 replies (of 1 total)
  • I have used <?php echo get_post_meta($post->ID, 'page-title', true); ?>
    which still works for all pages but the ‘News’ Page (this time displaying nothing).

Viewing 1 replies (of 1 total)
  • The topic ‘Having trouble moving page name on the ‘blog’’ is closed to new replies.
Skip to toolbar