• I’m looking for a tip on how to prevent a single post or the entire category (there’s only one post in it) from appearing on the home page.

Viewing 7 replies - 1 through 7 (of 7 total)
  • There are a couple of plugins for this.

    Unfortunately the site they reside on appears dead at the moment. Here’s the links to them (for when things are back in order):

    https://dev.wp-plugins.org/file/front-page-cats/trunk/
    https://dev.wp-plugins.org/browser/elegant-category-visibility/trunk/

    thanks kaf!

    Thread Starter mgm_03

    (@mgm_03)

    This isn’t exactly what I need but is an alternative solution: https://www.ilfilosofo.com/blog/home-page-control/

    Thread Starter mgm_03

    (@mgm_03)

    Ok. I found a solution after some effort looking. The plugin that I know works for WP 2.0 is at ……:

    https://ryowebsite.com/?p=46

    I needed this because I included a Flash Photo Gallery (SlideShowPro) that could only be inserted into a POST. Not wanting the gallery to appear on the home page, I needed a solution. This plugin worked without a hitch. Here’s the site I used it on : https://bearcabinrecording.com

    I’m using the Semiologic Opt-in front page plugin. It includes any post with the category “Blog”. I have that checked as default. Now everything is automatically appears unless I ‘opt-out’ by unchecking the blog category.

    Now I just want to hide that category from the post meta data.

    I need to modify this to exclude one category:

    get_the_category_list(‘, ‘)

    I think I need to insert exclude=’cat ID #’ somewhere. Anyone know how to do this? Thanks.

    I think this is what you have been looking for.
    https://ryowebsite.com/wp-plugins/category-visibility/

    I am having problems modifying the code for the Category Visability plugin so that it displays subcategories correctly. I used the following snippet, but keep getting an error.

    This is the snippet:

    Have found a fix for my problem, a bit clunky perhaps, but it works for 2 levels of subcategories, At line 322, change the part of the for each statement as follows:

    foreach ($linklist as $link) {
    if(preg_match("/class.children/”, $link)) {
    $children = 1;
    $newlist .= $link;
    } elseif(preg_match(”/class.children/”, $link) && ($children=1)) {
    $children = 2;
    $newlist .= $link;
    } elseif(preg_match(”/</ul>/”, $link) && ($children=1)) {
    $children = 0;
    $newlist .= $link;
    } elseif(preg_match(”/</ul>/”, $link) && ($children=2)) {
    $children = 1;
    $newlist .= $link;
    } else { ….. (ETC)

    This is the error:
    Parse error: parse error, unexpected T_CLASS in D:\Domains\go.id.au\wwwroot\wp-content\plugins\category_vis-rh.php on line 339

    Line 339 is

    } elseif(preg_match(”/class.children/”, $link) && ($children=1)) {

    Any suggestions as to what I need to edit to make this work?

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘How do I exclude a post or category from home page’ is closed to new replies.