Forums

[resolved] wp_list_pages attributes only functioning for Admin (4 posts)

  1. moabman1
    Member
    Posted 2 years ago #

    This problem is driving me nuts ... As best as I can tell, the wp_list_pages attributes aren't being recognized unless I am logged in as an admin (I tried various other levels without success). Anyone have any ideas why that might be?

    The background: I have a set of parent pages that act as a horizontal top Nav and a set of child pages for most parent pages that appear horizontally underneath the top Nav.

    After upgrading to 2.9.1 I discovered my submenus were not appearing. Moreover, it was causing the entire page to simply stop loading, though no PHP errors were appearing.

    After experimenting I discovered that the subnav only appears properly to me when I'm logged in as a Administrator. My subscribers and non subscribers either see all the parent and sub parents navs at once or see nothing as I noted above. Changing the attributes appear to be having no effects on the wp_list_pages tag.

    Finally, I created a page and tested different nav/subnav code chunks. Whether I used custom chunks of nav code from other sites or code from here: http://codex.wordpress.org/Template_Tags/wp_list_pages, the results were the same.

    Here is an example page of the incorrect output vs. what should appear based on the code http://www.ewillys.com/?page_id=16894

    BTW: I have tried reinstalling 2.9.1, but this had no effect.

    Thanks,

    Dave

  2. moabman1
    Member
    Posted 2 years ago #

    UPDATE ... ok, I've narrowed the problem down to this. When logged in as administrator I am able to get results when I try to call for the page ID number such as:

    .$post->ID

    But, when not logged in as an admin, I can't get any results from that equation. This is what is causing my php sub page request to fail.

  3. moabman1
    Member
    Posted 2 years ago #

    UPDATE II ... Using this code

    <?php
    $thePostID = $post->ID;
    echo $thePostID;
    $thePostParentID = $post->post_parent;
    echo $thePostParentID;
    ?>

    I've determined that no results occur unless logged in as administrator.

  4. moabman1
    Member
    Posted 2 years ago #

    RESOLVED .. I discovered there was a conflict between the javascript related to sponsors-slideshow-widget and the problems above. Removing that plugin solved the issue.

Topic Closed

This topic has been closed to new replies.

About this Topic