[wp-hackers] Custom Page Template - can't see the forest through the trees

Mike Walsh mpwalsh8 at gmail.com
Fri Apr 2 16:40:53 UTC 2010


On Fri, Apr 2, 2010 at 11:40 AM, John Bloch <jbloch at olympianetworks.com>wrote:

> Mike,
>
> Are you running it in a loop?
>
> Either way, I always use get_posts instead of starting a separate query. It
> has basically all the same options. For that, you'd use
>
> <?php
> $new_posts = get_posts( 'category=23' );
> foreach( $new_posts as $post ):
> setup_postdata( $post );
>
> endforeach;
> ?>
>
> [ ... snipped ... ]


This works great and is doing what I want.  Now all I need to do is figure
out why the comment reply form is being shown for each post instead of the
typical post footer content.

Thanks,

Mike


More information about the wp-hackers mailing list