• hi
    i switched on wordpress and i am very satisfied so far.

    all i need now, is to hide pages from the navigation menu (like the “about” near “home”)

    in other templates, it is as easy as adding an “Exlude code” on header.php but i cant find it on vistalicious template!

    any recommendations?
    help in advance!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Look in the header.php file–it does a weird thing to get the pages–anyways I didn’t test this but assuming About is ID=2 in your wp_posts table, change

    $these_pages = $wpdb->get_results('select ID, post_title from '. $wpdb->posts .' where post_status = "publish" and post_type = "page" order by ID');

    to

    $these_pages = $wpdb->get_results('select ID, post_title from '. $wpdb->posts .' where post_status = "publish" and post_type = "page" and ID <> "2" order by ID');

    no idea how that is impacted by the get_cache line 36 in that header.php, but try the above.

    Otherwise you’d have to do an exclude in list_all_pages function…

    Thread Starter nikosgr

    (@nikosgr)

    i’ve already tried the exclude in list all pages but didnt worked. maybe i havent done it correctly. i will try the other one and let the forum know, if it works!

    thanks a lot for your time michael 🙂

    Thread Starter nikosgr

    (@nikosgr)

    it worked!
    cheers!

    Thanks! I had the same problem and the reco worked great. Indeed, a weird script to get the pages …

    Now, a second question … how to exclude more than one page from showing?

    Any ideas?

    Thanks in advance

    Ok … I asked … I tried … I answer …

    For multiple pages, a simple iteration:

    … and ID <> “n”…

    will work.

    Cheers!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘excluding a page from navigation on vistalicious theme’ is closed to new replies.