I’m building list of the posts from the first wordpress loop to remove it in the second one, to avoid duplicate content on the homepage. So I have an array:
$do_not_duplicate_slider[] = $post->ID;
Now I’d like to remove these posts from the secondary loop:
query_posts( 'order=DESC&orderby=modified&posts_per_page=4&post_type=post&category_name='.$myCity );
How do I pass $do_not_duplicate_slider in this string?
Under codex I read it is possible to do it in array like so: post__not_in => $do_not_duplicate_slider
But since my query is string based, I’d like to continue this way instead of rewriting everything in an array. Is there a way to do it?
You can try with :
Or with an array :