Get current post ID and exclude
-
I have the following in my single.php file:
query_posts(array('showposts'=> 4,'cat' => 5,'post__not_in' => array('current-post-id-here')));but what I’m wanting to do is to get the current post’s ID and then have that entered into where I’ve added “current-post-id-here” in the above code. After that I am listing the latest 4 posts underneath the main post content.
I’d really appreciate any help with this.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
The topic ‘Get current post ID and exclude’ is closed to new replies.