get_posts php issue
-
on this PAGE of my site (https://greenrefurbishing.com/wordpress/blog/), I have the php code below pasted in the HTML content editor of the PAGE in order to show the entire most recent post to the Blog category (category 1).
but for some reason, the title of the post does not appear, even though the Posted On date does, and so does the content.
how do I get the post title to appear? Please advise. Thanks!
<?php $latestposts = get_posts('numberposts=1&category=1'); foreach($latestposts as $post) : setup_postdata($post); ?> <a href="<?php the_permalink(); ?>"><?php the_title(); ?></a><br /> <?php twentyten_posted_on(); ?><br /> <br /> <?php the_content(); ?> <?php endforeach; ?>
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘get_posts php issue’ is closed to new replies.