• hello people, can you help me?

    i want to make wordpress show posts only from a category called for example “general” and the other posts under categories “photos”, “music” and stuff like that to be invisible

Viewing 8 replies - 1 through 8 (of 8 total)
  • Hello

    <?php wp_list_cats('sort_column=name&optioncount=1&exclude=1, 2, 3, 4, 5, 6'); ?>

    Change 1, 2, 3, 4, 5, 6 to match the category id numbers that you want to exclude.

    Hope it helps :)`

    Thread Starter thestaticbot

    (@thestaticbot)

    i didn’t understood that,

    the site i’m builing is for a music band that will use wordpress as a publishing system.

    so the main page is the news page and i have a menu with links to diferent categories, for example in the categorie photos, i’ll put photos from their concert so each post will contain diferent photos, so i need to post something that matches the categorie “photos” and it will apear that…

    i can use the general category for the news, but in this case i need to find a way to make the system to forward me to the link of that categorie so for example

    sitename.com/blog would send me to sitename.org/blog/general

    any way to do that?

    I gotcha, Another guy was trying to help me out and they were making it to difficult.

    Just above the line <?php if (have_posts()) : ?>

    Add This
    <?php query_posts(‘cat=1’); ?>

    Now in order to to view your other categories you will need to duplicate that page and rename it to “whatever.php” and change this to
    <?php query_posts(‘cat=2’); ?> where 2 == the category of posts you wish to show.

    That is about as quick and dirty of a hack as I can think of

    Thread Starter thestaticbot

    (@thestaticbot)

    but how i make other categories open the right watheaver.php file? like photos.php is for the photos categorie and so on?

    category visibility

    this plugin does it for you
    ??
    regards
    Monika

    Thread Starter thestaticbot

    (@thestaticbot)

    wow, thanks a lot MONIKA!!!!!!

    Thread Starter thestaticbot

    (@thestaticbot)

    then i activate the plugin on my machine(i’m using xampp software to have wordpress instaled on my windows comp) it’s all cool but then i upload it and activate it on my server i get this error:

    WordPress database error: [Table ‘moesimpl_wp1.wp_cat_visibility’ doesn’t exist]
    SELECT cat_ID from wp_cat_visibility

    thestaticbot
    I’m not the coder of this plugin,
    please ask him

    I’m using this plugin without any error
    regards
    Monica

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘how to make it show only one categ in front page’ is closed to new replies.