Let’s say the page i’m displaying has the title “About” and the id is 49. Is there a way to change it so it pulls the pages title instead of the id.
At the moment the code I am using is as follows:
<?php
query_posts('page_id=49');
while (have_posts()) : the_post(); ?>
<?php the_content();
endwhile;
?>
Thanks for your help!
I used something similar on a project, using the post’s
slug; save this in your theme’sfunctions.php:Usage: