Support » Plugin: My Page Order » [Plugin: My Page Order] not changing the order on the site

  • I installed the My page order plugin and it appears to work well in the administrative screens. When I drag my pages into the order that I want and tell it to set the order it appears to do so and it changes how they appear in the dashboard/pages screen. It does not however change how they are ordered when I view the page. I am using the Picture Perfect theme with a sliding menu. my web address is http://www.schandorfffamily.com. I know you have probably already answered this question for others by I couldn’t tell if that answer applied to me and the theme I am using. If I do need to change the code please be specific about where to change it because I do not have much PHP experience.
    thanks for a good plugin and the help.

    Tim

Viewing 15 replies - 1 through 15 (of 49 total)
  • Plugin Author froman118

    (@froman118)

    Yup, looks like it is hardcoded to use the page ID. In header.php on about line 50 there’s this line:

    <?php slider_menuparse(wp_list_pages('sort_column=ID&depth=1&number=7&title_li=&echo=0')); ?>

    replace it with this:

    <?php slider_menuparse(wp_list_pages('sort_column=menu_order&depth=1&number=7&title_li=&echo=0')); ?>

    That should do it.

    thanks for the help. Got it all figured out and you are right that was the problem.

    Tim

    Hi,

    I seem to be having the same problem as Tim. I’m using the Dirtylicious theme and have found wp_list_pages(‘depth=1&title_li=&before=–’) in my header.php Is this what’s causing my problem, and if it is, what do I replace it with?

    The site I’m working on is http://www.picturehouseantiques.co.uk

    Thanks!

    Plugin Author froman118

    (@froman118)

    hisforhome,

    Take that line and switch it to this:

    wp_list_pages(sort_column=menu_order&’depth=1&title_li=&before=–’)

    That should get things ordered correctly.

    Hi froman118,

    Thanks for your help. I’ve just updated the line to what you said but I now get a HTTP – 500 Internal Server Error message

    Plugin Author froman118

    (@froman118)

    Oops sorry, misplaced the quote:

    wp_list_pages(‘sort_column=menu_order&depth=1&title_li=&before=–’)

    Thanks again froman118,

    This time I didn’t get an error message, the pages have just lost all their formatting

    Thanks,
    hisforhome

    Plugin Author froman118

    (@froman118)

    Copy and paste the whole header.php in here, there’s something wrong with the syntax.

    Hi froman118<

    Thanks again for all your help. Here’s the whole thing:

    <!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>

    <html xmlns=”http://www.w3.org/1999/xhtml”>

    <head profile=”http://gmpg.org/xfn/11″>

    <meta http-equiv=”Content-Type” content=”<?php bloginfo(‘html_type’); ?>; charset=<?php bloginfo(‘charset’); ?>” />

    <title><?php bloginfo(‘name’); ?><?php if ( is_single() ) { ?> » Blog Archive <?php } ?><?php wp_title(‘ » ‘); ?></title>

    <meta name=”generator” content=”WordPress <?php bloginfo(‘version’); ?>” /> <!– leave this for stats –>

    <link rel=”stylesheet” href=”<?php bloginfo(‘stylesheet_url’); ?>” type=”text/css” media=”screen” />

    <link rel=”alternate” type=”application/rss+xml” title=”RSS 2.0″ href=”<?php bloginfo(‘rss2_url’); ?>” />

    <link rel=”alternate” type=”text/xml” title=”RSS .92″ href=”<?php bloginfo(‘rss_url’); ?>” />

    <link rel=”alternate” type=”application/atom+xml” title=”Atom 0.3″ href=”<?php bloginfo(‘atom_url’); ?>” />

    <link rel=”pingback” href=”<?php bloginfo(‘pingback_url’); ?>” />

    <?php wp_get_archives(‘type=monthly&format=link’); ?>

    <?php wp_head(); ?>

    </head>

    <body>

    <div class=”outer-container”>

    <div class=”inner-container”>

    <div class=”header”>

    <div class=”title”>

    <span class=”sitename”>/”><?php bloginfo(‘name’); ?></span>
    <div class=”slogan”><?php bloginfo(‘description’); ?></div>

    </div>

    </div>

    <div class=”path”>

    /”>Home

      <?php wp_list_pages(‘depth=1&title_li=&before=–’);?>

    </div>

    <div class=”main”>

    <div class=”content”>

    Plugin Author froman118

    (@froman118)

    You should be alright, I still had a window open of your site when I first looked at it and they links across the top looked the same. It also looks the same as this demo, http://templates.arcsin.se/demo/dirtylicious-wordpress-theme/

    Sorry, I’ve not been terribly clear. I want to change the order of the sub pages of the “Dealers” page down the left column.

    Thanks

    …so I guess that means the sub-sub pages 🙂

    Plugin Author froman118

    (@froman118)

    Ahhh ok, in functions.php replace existing wp_list_pages() call with this:

    wp_list_pages('sort_column=menu_order&title_li=&child_of='.$subpages);

    Whoops- just tried that and I’m getting another HTTP – 500 Internal Server Error message!

    Plugin Author froman118

    (@froman118)

    It should be fine check for types, whole function would look like this:

    function the_subpages()
    {
    	global $post, $wpdb;
    
    	if ( is_page() )
    	{
    		if ( $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->posts WHERE post_type='page' AND post_parent = ".$post->ID) > 0 ){
    			$subpages = $post->ID;
    		}
    		else if ( $post->post_parent != 0 ){
    			$subpages = $post->post_parent;
    		}
    
    		if ($subpages)
    		{
    			echo '<h2>Subpages</h2>' . "\n";
    			echo '<ul>' . "\n";
    			wp_list_pages('sort_column=menu_order&title_li=&child_of='.$subpages);
    			echo '</ul>' . "\n";
    		}
    	}
    }
Viewing 15 replies - 1 through 15 (of 49 total)
  • The topic ‘[Plugin: My Page Order] not changing the order on the site’ is closed to new replies.