• daand

    (@daand)


    What if 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

The topic ‘Exclude the current post in the get posts code’ is closed to new replies.