Top

daand on "PHP code in template tag"

May 28, 2010 by  

What is i want to exclude the current post in the get posts code?

$postslist = get_posts(‘numberposts=1000&order=ASC&exclude=….&orderby=date&cat=’ . $cat_id);

In which case … should be the current post ID.

The current post ID template tag is; the_ID() I thought.

I would very much appericiate it when someone could explain how it works, because i dont want to bother you every time..

Thanks in advance!
Daan

Be Sociable, Share!
Share

Comments

Facebook comments:

Feel free to leave a comment...
and oh, if you want a pic to show with your comment, go get a gravatar!





*
Bottom