• Has anyone some hint how it can be arranged that posts belonging to a certain category (and only to this category) are skipped in the loop?
    Copying the_content() to another name and checking in the new function for a certain category is simple, but won’t help (everything else like the date and such is still there and even if I repeat that for a handful of tags the div’s etc. are still in there — no way).
    I think I have to lay my cold hands on the loop itself and get the posts belonging to that category somehow deleted from the $posts array, so that they are completely skipped. But how? Where? Do I really have to dive into wp-blogheader.php? There is not a single function defined in there, just rock-bottom PHP, building SQL queries in a quite frankensteinish way… This would mean I had to hack that file, no clean way to get a grip here from within a plugin.
    Any ideas? Please?
    Well, I could write a function that goes over $posts and massages it into $my_posts, leaving the unwanted posts behind… Hmm.That might be doable in a plugin and I just had to use $my_posts in the loop then. Ok, I’ll look into that.
    Am I talking to myself? Yeah, well. Thanks for listening anyway. Any better ideas?

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Skipping posts in The Loop by category?’ is closed to new replies.