WordPress.org

Ready to get started?Download WordPress

Forums

Help using 'fold page list' plugin (8 posts)

  1. jhob
    Member
    Posted 6 years ago #

    I am looking for some help with using the fold page list plugin.

    I have it running on a site that I am developing here: http://www.privileged.group.shef.ac.uk/

    From second level and below is displayed in the left hand menu. It works fine when clicking on a second level menu item and correctly displays the third level menu item in the menu. However, when clicking on a third level menu item the second level menu items disappear and the third level items become the top level and their children are displayed.

    The code that I have generating the menu is:

    <ul>
    <?php
    $thispage = $wp_query->post;
    if($thispage->post_parent!=0) //if not top level
    {
    wswwpx_fold_page_list("depth=3&title_li=&child_of=".$thispage->post_parent);
    }
    else //if top level
    {
    wswwpx_fold_page_list("depth=3&title_li=&child_of=".$thispage->ID);
    }
    ?>
    </ul>

    I have been playing around with various permutations for ages now but have not come up with anything that actually works as I want it to.

    Does anyone know how I can get it so that a single branch will keep expanding to the nth level but still display all of the current page's ancestors, but still excluding the first level menu items which are only displayed on the horizontal menu?

    Many thanks,
    John

  2. jhob
    Member
    Posted 6 years ago #

    Hi all,

    I am still stuck with this one. If anyone is able to offer help, I'd appreciate it.

    thanks,
    John

  3. jhob
    Member
    Posted 6 years ago #

    help still required if anyone is so inclined to offer it...

  4. scormeny
    Member
    Posted 6 years ago #

    Have you tried writing directly to the developer? I've written to him before and he's been helpful.

    Best of luck!

  5. Doodlebee
    Member
    Posted 6 years ago #

    Yeah, I've done this before, actually. I have to dig up the files though...gimmie a minute.

  6. Doodlebee
    Member
    Posted 6 years ago #

    Okay - had to do some major digging, because it was well over a year ago when I solved this problem for a client's site.

    Sp you first need to open up the plugin file - fold_page_list.php. Towards the bottom is where you need to edit the plugin to change the formatting and display. Forgive me if I don't have time to figure out which lines of code I actually changed, but I copied the relevant stuff and posted it on pastebin for you to look at. Although it starts at line 1 in pastebin, you actually want around line 184 in the actual file.

    Then in the sidebar, you just call the plugin as you normally would (<?php wswwpx_fold_page_list('title=li' ?>)

  7. jhob
    Member
    Posted 6 years ago #

    Thanks so much for the reply! I'll try it out later and let you know how I get on.

  8. quirksmode
    Member
    Posted 6 years ago #

    Hi, I couldn't get this to work, is there a solution? When I click an item within a child page the subnav disappears. My other problem is that my url does not display properly either. It jumps from

    http://www.mywebsite.com/portfolio

    to

    http://www.mywebsite.com/childitem

    when i want it to show

    http://www.mywebsite.com/portfolio/childitem

Topic Closed

This topic has been closed to new replies.

About this Topic