OnPoint Plugins

  • Plugins
    • Advanced Sidebar Menu
    • Go Live Update Urls
  • About
    • Services
    • Showcase
  • Blog
  • Contact
  • Support
  • Log In
← Back to support

Create site map of the whole website

Resolved

Requested: 2 years and 3 months ago

Hi,

I know this probably goes against the plugin main functionality, but would it be possible to create an automatic accordion menu with all the pages (and their hierarchy) of the whole website?

If so, how should I proceed?

Thanks in advance!

Plugin: Advanced Sidebar Menu

  1. OnPoint Plugins

    2 years and 3 months ago

    Hi Ricardo,

    There are two approached to accomplishing. Both will require the following widget options:

    1. Always display child pages = checked
    2. Maximum level of child pages to display = Total levels of pages your site has.
    3. Display widget on every page = checked
    4. Top level parent page to use for this widget = You highest level parent page.
    5. Enable accordion menu = checked
    6. Include highest level parent in accordion = checked

    The first approach requires your site have a common highest level page. All pages on your site should be children or grandchildren of this top level parent. Using the following additional widget options will make everything work:

    1. Display highest level parent page = unchecked

    The other approach will work if you site has various top level parent pages and does not require all pages to be children or grandchildren of a common parent. First set the following addition widget options:

    1. Display highest level parent page = checked

    You will then need to use a template override in your theme to change the structure of the menu

    1. Create a new folder in your active theme called advanced-sidebar-menu.
    2. Create a new file within the new folder called page_list.php.
    3. Add the following code to the new file.


    You menu will then contain all top level pages and their children with accordion functionality.

  2. geral

    2 years and 3 months ago

    Hi,

    Thank you so much for your reply!

    I tried approach 2 and while it works to make a site map, however it also applies to all the other menus and I definitely don’t want that. Is it possible to apply this new behaviour to just one accordion id?

    Thanks again!

     

  3. OnPoint Plugins

    2 years and 3 months ago

    Hi Ricardo,

    If you would like to target a specific widget you may add this code near the top of the template and change the id to match your widget:

    If you would like to target a specific sidebar you may add this code near the top of the template and change the id to match your sidebar:

    The end result will be something like this:

New Response Cancel reply

You must be logged in to respond. Only PRO members are allowed to respond to support requests.

© 2023 · WordPress Development · Terms Of Service · Privacy Policy · Cookie Policy · Log in

  • Plugins
  • Blog
  • Contact