Change WordPress user roles and capabilities Forums How to or FAQ How to prevent protected pages to be listed on parent pages ?

Tagged: ,

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #6606
    Malaiac
    Participant

    Hello,

    Just bought the Pro version. Working on protecting some Pages and some Articles

    If a page A is public, and has two subpages B and C. B is restricted to role1, role2, C is public
    If I do a wp_list_pages (or a get_pages(children of A) ), how can I have the B page hidden for the regular visitor and visible for role1, role2 ?

    #6609
    Vladimir
    Keymaster

    Hi,

    Set ‘access error action’ for page B to ‘404 HTTP error’. This option excludes page from all WordPress listings.

    #6610
    Malaiac
    Participant

    That worked ! Thanks

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.