• I’m using the theme “minima-black-for-wordpress-115” and trying without success to get the pages to display in the sidebar according to assigned page numbers. I edited the sidebar.php file from the minima theme folder and added the following:

    <?php wp_list_pages( ‘sort_column=menu_order’ ); ?>

    I uploaded it to the site, tried various things to get the page order to change, but nothing worked. It continues to show the pages alphabetically, the default. Is there something else I need to do? Is there another file beside sidebar.php I need to edit? The site is http://www.jeffcox.com/jcblog/ if you need to take a look. Odd, but in the ‘Page Management’ screen the pages do display in the correct order, but not on the public side. Any help would be very much appreciated. Thanks.

Viewing 12 replies - 1 through 12 (of 12 total)
  • This statement caused me a bit of confusion:

    trying without success to get the pages to display in the sidebar according to assigned page numbers.

    Are you setting the Page Order on each of your Pages? That’s what the menu_order is sorting on.

    If you want those Pages displayed in ID order, then the sort_column=ID would be the way to go with the template tag, wp_list_pages().

    Thread Starter -jc

    (@-jc)

    No, I’m not trying to display by ID number, but by the “Page Order” input box at the bottom of the right column on the Manage / Pages screen. Say the title is “Writing” and I put in the number “1”. The “Writing” page still comes up at the bottom of the sidebar menu. Thanks for responding, I’ve hours and hours trying to get this to work.

    I put your code in the wp-content/themes/default/sidebar.php file and had no problem displaying pages in the order dictated by the Page Order I set on each Page.

    In addition, I tested the Pages Widget with the WordPress Default 1.6 theme and it worked as expected when I set the Sort by order to Page order.

    Thread Starter -jc

    (@-jc)

    Well, I just tried a different theme – Dark Pleasure – 10 – and it works fine, exactly as it should. So my guess is that it’s something to do with the Minima theme. As I’d still like to use Minima, any thoughts? Thanks once again – I’m learning and doing on the fly, and I appreciate your help.

    Link to download theme, please.

    Thread Starter -jc

    (@-jc)

    This is what I downloaded:

    http://themes.wordpress.net/columns/2-columns/2554/minima-black-for-wordpress-115/

    Aside from that one edit to sidebar.php I have not touched any of the theme files. Does the age of the theme matter? I downloaded the minima theme this past September, but it seems to have been written for WP 1.1.5 or 1.1.6 – which as I recall from something read in the codex may have been prior to the page order / number sorting abiltiy.

    I’ll check back in a while, and if I happen to figure it out on my own, I’ll post what happened. For now, I think I’m just going to go with the Dark Pleasure 10 theme or one of the others. That solves the functionality problem, and I’ll worry about the aesthetics later. Thanks again.

    With that theme, NOT using Widgets, if I change line 7 in sidebar.php to
    <?php wp_list_pages( 'sort_column=menu_order' ); ?>

    it does display pages in the Page Order I’ve assigned.

    Thread Starter -jc

    (@-jc)

    Let me try that … when you say “NOT using widgets” I’m not sure what you mean – is there a way to turn off widgets? Should I do that?

    Also, I think I was wrong about the theme-age theory. And switching to Dark Pleasure solves the page order issue, but creates some others. Grrr!

    Widgets are OFF if there is no Widget in the Sidebar 1 box under Presentation->Widgets.

    Thread Starter -jc

    (@-jc)

    BINGO!!!! I removed all the widgets, and it works. Thank you, thank you!

    Remember, the Pages widget can be configured to set the order also.

    See Widgets_SubPanel.

    Thread Starter -jc

    (@-jc)

    Once I get the basics squared away, I’ll look into it. Take care.

Viewing 12 replies - 1 through 12 (of 12 total)

The topic ‘Problem with wp_list_pages – not working’ is closed to new replies.