WordPress.org

Ready to get started?Download WordPress

Forums

Page Order for Newbies (6 posts)

  1. DoctorWatson
    Member
    Posted 6 years ago #

    Hello.

    My question is simple : why does WordPress ignore the order of pages assigned when you write them ? Whatever I try, they always appear in alphabetical order. I really need them in the order I define.
    I have found many other posts on this problem, but all of the answers and information seems to be for Learned Ones or Code Gurus only.
    I am a newbie to WordPress and to php, so all that stuff in the manual http://codex.wordpress.org/Template_Tags/wp_list_pages is still quite like Latin to me.
    Could someone please tell me exactly what to change and in which file ?
    If members of the developers team read this (no harm meant) : what is the use of providing an option that doesn't work in the first place ? If you offer the option to determine page order on the Write Page screen, then that should be the default I think.

    Greetings,

    Michel Van Passel

  2. DoctorWatson
    Member
    Posted 6 years ago #

    *Sigh* I thought I had found a solution myself ....
    Somewhere in all those posts about the page order problem (so it seems to be a real tough opne), I came across a plugin "mypageorder" from Froman118 (?) - http://geekyweekly.com/. I made sure to install the right version.
    Result : Nothing changes. OK, you can set the page order in an easy way compared to setting it for each individual file. But when viewing the site, the pages are still in alphabetical order.
    I really need my ages to be ordered like I want them.
    Please help a newbie !

  3. DoctorWatson
    Member
    Posted 6 years ago #

    After two days of intensive research I found the solution myself. Method used : Trial and Error.
    Perhaps it's all obvious for Gurus …
    So for the record - if another newbie would stumble by :
    Somewhere in one of the .php files of the theme you are using, you will most probably find a template tag that will list your pages in alphabetical order: <?php wp_list_pages(); ?> (default with "Pages" as title) or <?php wp_list_pages('title_li='); ?> (the same but without the title).
    To make it list the pages in the order you have defined, just change this to <?php wp_list_pages('sort_column=menu_order&title_li='); ?>.

    Michel

  4. Ivovic
    Member
    Posted 6 years ago #

    Hi Doc,

    A lot of theme authors are nice/smart enough to put this into their themes by default, but I guess not all of them :( ... and that's the crux of it really.

    WordPress offers the feature quite rightly, but unfortunately not all themes take advantage of it.

    I'm sorry I didn't see your post sooner as that's something I had to do myself as well. Thanks for coming back and contributing the solution.

  5. froman118
    Member
    Posted 6 years ago #

    Direct link to My Page Order now hosted on Extend:

    http://wordpress.org/extend/plugins/my-page-order/

  6. Tim Squires
    Member
    Posted 5 years ago #

    I've had a good search through the theme that I am using (Neoclassical) and I cant find wp_list_pages etc anywhere. If anyone has any feedback on where to find the code in this thene it would be great.
    Thanks :)

Topic Closed

This topic has been closed to new replies.

About this Topic