• Resolved kier1989

    (@kier1989)


    I want to make it so that my pages that I create some of them are hidden, but some are not hidden if that makes any sence. Is there a way to do this?

Viewing 7 replies - 1 through 7 (of 7 total)
  • If you mean hiding them in the sidebar’s menu – you just have to take a look at the template tag used to display the Pages > see here Template_Tags/wp_list_pages and apply the “exclude” parameter.

    Thread Starter kier1989

    (@kier1989)

    ok thanks for that, one more question where does that code go? What file is it?

    Since I don’t have a link to your site and because you didn’t tell in your original post what theme is active on your blog… I don’t know.

    Most themes have the Pages displayed in the sidebar.php.

    Thread Starter kier1989

    (@kier1989)

    ok, I added that bit of code into the sidebar.php and it does not work.

    My site is
    https://allthingsrandom.co.uk/blog/

    Do you know why? I want to hide the page jokes and testing.

    So, how does your bit of code look like? the wp_list_pages?
    Did you add the exclude parameter as it is shown in the example shown on the Codex page I linked above?

    Thread Starter kier1989

    (@kier1989)

    I thought that I needed to add that code to sidebar.php, I dont know where wp_list_pages is, where would it be?

    I’ve found the wp_list_pages, do I just add that code to there?

    Edit – I’ve done it now, thanks for your help.

    it would be great if you could write, where you found the wp_list_pages, now that you know. thanks.

    k

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Hide pages’ is closed to new replies.