• Hi there, for the most part, I love this plugin, but seem to be having issues with duplicates and odd ordering.

    We are using a custom post type, products, and they are listed on a category archive. We use the following code:

    [ajax_load_more category="'.$category.'" post_type="products" orderby="menu_order" posts_per_page="12" max_pages="0" order="ASC" offset="0" scroll_distance="300" button_label="More Products" category__not_in="14,18"]

    It seems that using menu_order really upsets this plugin. Let’s say there’s 40 products to be displayed. Using orderby="name", everything works fine. 12 items load alphabetically, then as you scroll, the next 12 do.

    With menu_order, 12 load in the incorrect post order, then the next 12 load, with duplicates. If there’s 40 items to load, it might only load 28, as an example.

    Am I doing something wrong here? Would love to know how to fix this. Thanks.

Viewing 14 replies - 1 through 14 (of 14 total)
  • Plugin Author Darren Cooney

    (@dcooney)

    Hi @unexploded,
    Sounds more like an issue with your repeater template than menu_order.

    Can you post your template?

    Thread Starter unexploded

    (@unexploded)

    Hey thanks for the quick reply, sure can:

    <?php get_header(); ?>
    <div id="page">
    <!--content-->
    <div class="section group">
    <div id="content" class="col span_12_of_12">
    <h2><?php single_cat_title(); ?></h2>
    <p><?php echo category_description( $category_id ); ?></p>
      <?php 
    $cat = get_category( get_query_var( 'cat' ) );
    $category = $cat->slug;
    echo do_shortcode('[ajax_load_more category="'.$category.'" post_type="products" orderby="name" posts_per_page="12" max_pages="0" order="ASC" offset="0" scroll_distance="300" button_label="More Products" category__not_in="14,18"]');
    ?>
    </div>
    </div>
    <!--push-->
    <div class="clear"></div>
    <div class="push"></div>
    <?php get_footer(); ?>
    
    
    Plugin Author Darren Cooney

    (@dcooney)

    Sorry, your Repeater Template, not page template 🙂

    Thread Starter unexploded

    (@unexploded)

    Sorry my bad! Here we go:

    
    <a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title(); ?>">
    <div class="products-list-item">
    <?php if (has_post_thumbnail( $post->ID ) ): ?>
    <?php $image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'medium' ); ?>
    <div class="products-list-item-image" style="background-image: url('<?php echo $image[0]; ?>')">
    <?php else : ?>
    <div class="products-list-item-image" style="background-image:url('http://cablejointingsolutions.co.uk/wp-content/uploads/2015/12/no-image.jpg');">
    <?php endif; ?>
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle"><?php the_title(); ?></h3>
    <?php the_excerpt(); ?>
    </div>
    </div></a>
    
    Plugin Author Darren Cooney

    (@dcooney)

    Hmm, template looks good.
    I just tested the following shortcode and it works as expected on my dev install.

    [ajax_load_more post_type="movie" orderby="menu_order" order="ASC" posts_per_page="1"]

    Which plugin are you using for ordering the pages? Maybe there is an issue there.

    Thread Starter unexploded

    (@unexploded)

    Hi there, really appreciate the quick replies!

    I don’t know what to say, every time I use menu_order it creates those problems I have explained above.

    The link in question is : http://test.s7media.net/earthmet/category/product-range/earthing/

    So at the moment, that’s set up to use menu_order. You’ll see as you scroll, it duplicates (the plastic cable clamps as an example).

    On alphabetical, it’s fine.

    Thread Starter unexploded

    (@unexploded)

    This is the generated HTML:

    
    <div id="ajax-load-more" class="ajax-load-more-wrap infinite skype alm-0" data-id="0" data-canonical-url="http://test.s7media.net/earthmet/category/product-range/earthing/" data-slug=""><div class="alm-listing alm-ajax   " data-repeater="default" data-post-type="products" data-post-format="" data-category="earthing" data-category-not-in="14,18" data-tag="" data-tag-not-in="" data-taxonomy="" data-taxonomy-terms="" data-taxonomy-operator="" data-taxonomy-relation="" data-meta-key="" data-meta-value="" data-meta-compare="" data-meta-relation="" data-meta-type="" data-year="" data-month="" data-day="" data-author="" data-post-in="" data-post-not-in="" data-exclude="" data-search="" data-custom-args="" data-post-status="" data-order="ASC" data-orderby="menu_order" data-offset="0" data-posts-per-page="12" data-lang="" data-scroll="true" data-scroll-distance="300" data-max-pages="0" data-pause-override="false" data-pause="false" data-button-label="More Products" data-button-class="" data-destroy-after="" data-transition="slide" data-images-loaded="false"><div class="alm-reveal"><a href="http://test.s7media.net/earthmet/products/earth-rods/" rel="bookmark" title="Earth Rods (Copperbonded)">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/Copper-Bonded-Grounding-Earth-Rod-300x154.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Earth Rods (Copperbonded)</h3>
    <p>Earthmet stock all sizes of copperbonded earth rods</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/insulators-in005/" rel="bookmark" title="Insulators">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/in005.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Insulators</h3>
    <p>Earthmet supply all sizes of insulators.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/split-bolt-connectors/" rel="bookmark" title="Split Bolt Connectors">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/Split-Bolt-300x119.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Split Bolt Connectors</h3>
    <p>Earthmet supply all sizes of split bolts.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/pipe-clamp/" rel="bookmark" title="Pipe Clamp">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/pipe_clamp.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Pipe Clamp</h3>
    <p>Pipe Clamps</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/metal-tape-clips/" rel="bookmark" title="Metal Tape Clips">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/metal-tape-clips-300x191.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Metal Tape Clips</h3>
    <p>Earthmet supply all sizes of metal tape clips.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/single-hole-earth-point/" rel="bookmark" title="Single Hole Earth Point">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/single-hole-earth-point-192x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Single Hole Earth Point</h3>
    <p>Single Hole Earth Point</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/compression-terminals/" rel="bookmark" title="Lugs">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/lugs-300x225.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Lugs</h3>
    <p>Earthmet supply all types of lugs in all sizes. These can be made to order.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/two-hole-earth-point/" rel="bookmark" title="Two Hole Earth Point">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/two_hole_earth_points.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Two Hole Earth Point</h3>
    <p>Two Hole Earth Points</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/inspection-pit/" rel="bookmark" title="Inspection Pit">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/Earth-Inspection-Housing-150x150-1-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Inspection Pit</h3>
    <p>Earthmet supply both concrete and plastic inspection pits.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/earth-boss/" rel="bookmark" title="Earth Boss">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/earth_boss-300x116.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Earth Boss</h3>
    <p>Earth Boss</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/rebar-to-rebar-connecting-clip/" rel="bookmark" title="Rebar to rebar connecting clip">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/Rebar-to-rebar-clip-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Rebar to rebar connecting clip</h3>
    <p>Earthmet supply a range of rebar clips</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/static-earth-bar/" rel="bookmark" title="Static Earth Bar">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/Static-Earth-Bar-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Static Earth Bar</h3>
    <p>Static Earth Bar</p>
    </div>
    </div></a></div><div class="alm-reveal"><a href="http://test.s7media.net/earthmet/products/low-resistance-earthing-compound/" rel="bookmark" title="Low-Resistance Earthing Compound">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/low-resistance-earthing-compound-188x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Low-Resistance Earthing Compound</h3>
    <p>Earthmet supply a range of different bag sizes of the earthing compound.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/earth-rod-driving-stud/" rel="bookmark" title="Earth Rod Driving Stud">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/driving-stud.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Earth Rod Driving Stud</h3>
    <p>Earthmet supply all sizes of driving studs.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/b-bond/" rel="bookmark" title="B bond">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/Gunmetal-B-Bond-300x221.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">B bond</h3>
    <p>Earthmet supply all types of B bond</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/one-hole-plastic-cable-clamps/" rel="bookmark" title="One Hole Plastic Cable Clamps">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/one-hole-plastic-cable-clamps.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">One Hole Plastic Cable Clamps</h3>
    <p>Earthmet supply a range of sizes of one hole plastic cable clamps</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/inspection-housing-earth-bars/" rel="bookmark" title="Inspection Housing Earth Bars">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/Inspection-Housing-Earth-Bar-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Inspection Housing Earth Bars</h3>
    <p>Earthmet supply all sizes of earth bars.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/copper-lattice-mat/" rel="bookmark" title="Copper Lattice Mat">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/lattice-Mat-Blog-image-300x136.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Copper Lattice Mat</h3>
    <p>Earthmet supply the two common sized lattice mats</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/two-hole-plastic-cable-clamp/" rel="bookmark" title="Two Hole Plastic Cable Clamp">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/two-hole-plastic-cable-clamp.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Two Hole Plastic Cable Clamp</h3>
    <p>Earthmet supply several sizes of two hole plastic cable clamps.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/rod-to-tape-clamp-type-a/" rel="bookmark" title="Rod to Tape Clamp (Type A)">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/Type-A-Clamp.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Rod to Tape Clamp (Type A)</h3>
    <p>Earthmet supply all sizes of rod to tape clamps</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/earth-plate-solid-copper/" rel="bookmark" title="Earth plate – solid copper">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/earth-plate-solid-copper_1-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Earth plate – solid copper</h3>
    <p>Earthmet supply various sizes of copper earth mats </p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/brass-shear-off-lug/" rel="bookmark" title="Brass Mechanical Lug">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/BEt120-12-lug.png')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Brass Mechanical Lug</h3>
    <p>Earthmet supply all sizes of brass lugs</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/u-bolt-rod-clamp-type-guv/" rel="bookmark" title="‘U’ Bolt Rod Clamp (Type GUV)">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/cr700-2.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">‘U’ Bolt Rod Clamp (Type GUV)</h3>
    <p>Earthmet supply all sizes of U bolt clamps</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/earth-bars/" rel="bookmark" title="Earth Bars">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/copper-earth-bars-disconnectable-link_5-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Earth Bars</h3>
    <p>Earthmet supply all sizes of earth bars, tinned and plain and with and without disconnecting links.</p>
    </div>
    </div></a></div><div class="alm-reveal"><a href="http://test.s7media.net/earthmet/products/b-bond/" rel="bookmark" title="B bond">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/Gunmetal-B-Bond-300x221.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">B bond</h3>
    <p>Earthmet supply all types of B bond</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/one-hole-plastic-cable-clamps/" rel="bookmark" title="One Hole Plastic Cable Clamps">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/one-hole-plastic-cable-clamps.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">One Hole Plastic Cable Clamps</h3>
    <p>Earthmet supply a range of sizes of one hole plastic cable clamps</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/inspection-housing-earth-bars/" rel="bookmark" title="Inspection Housing Earth Bars">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/Inspection-Housing-Earth-Bar-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Inspection Housing Earth Bars</h3>
    <p>Earthmet supply all sizes of earth bars.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/copper-lattice-mat/" rel="bookmark" title="Copper Lattice Mat">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/lattice-Mat-Blog-image-300x136.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Copper Lattice Mat</h3>
    <p>Earthmet supply the two common sized lattice mats</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/two-hole-plastic-cable-clamp/" rel="bookmark" title="Two Hole Plastic Cable Clamp">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/two-hole-plastic-cable-clamp.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Two Hole Plastic Cable Clamp</h3>
    <p>Earthmet supply several sizes of two hole plastic cable clamps.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/rod-to-tape-clamp-type-a/" rel="bookmark" title="Rod to Tape Clamp (Type A)">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/Type-A-Clamp.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Rod to Tape Clamp (Type A)</h3>
    <p>Earthmet supply all sizes of rod to tape clamps</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/earth-plate-solid-copper/" rel="bookmark" title="Earth plate – solid copper">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/earth-plate-solid-copper_1-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Earth plate – solid copper</h3>
    <p>Earthmet supply various sizes of copper earth mats </p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/brass-shear-off-lug/" rel="bookmark" title="Brass Mechanical Lug">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/BEt120-12-lug.png')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Brass Mechanical Lug</h3>
    <p>Earthmet supply all sizes of brass lugs</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/u-bolt-rod-clamp-type-guv/" rel="bookmark" title="‘U’ Bolt Rod Clamp (Type GUV)">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/cr700-2.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">‘U’ Bolt Rod Clamp (Type GUV)</h3>
    <p>Earthmet supply all sizes of U bolt clamps</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/earth-bars/" rel="bookmark" title="Earth Bars">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/copper-earth-bars-disconnectable-link_5-300x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Earth Bars</h3>
    <p>Earthmet supply all sizes of earth bars, tinned and plain and with and without disconnecting links.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/rebar-clamp/" rel="bookmark" title="Rebar Clamp">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/09/Rebar-Clamp-249x300.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Rebar Clamp</h3>
    <p>Earthmet supply all sizes of rebar clamps.</p>
    </div>
    </div></a><a href="http://test.s7media.net/earthmet/products/rod-to-cable-lug-clamp-type-b/" rel="bookmark" title="Rod to Cable Lug Clamp (Type B)">
    <div class="products-list-item">
    <div class="products-list-item-image" style="background-image: url('http://test.s7media.net/earthmet/wp-content/uploads/2016/08/rod-to-cable-lug-clamp-type-b.jpg')">
    </div>
    <div class="product-list-desc">
    <h3 class="storytitle">Rod to Cable Lug Clamp (Type B)</h3>
    <p>Earthmet supply all sizes of rod to cable lug clamps</p>
    </div>
    </div></a></div></div><div class="alm-btn-wrap"><button id="load-more" class="alm-load-more-btn more">More Products</button></div></div>
    
    Thread Starter unexploded

    (@unexploded)

    Hi @dcooney did you have a chance to check out my last couple of posts?

    Plugin Author Darren Cooney

    (@dcooney)

    Hi @unexploded,
    No i didn’t because these frikken forums don’t order by most recent anymore.

    Maybe it’s something to do with the category query.
    Any chance you’ve tried removing the category__not_in parameter?

    Thread Starter unexploded

    (@unexploded)

    No worries! Grateful for your help so far.

    I have tried to remove that and no luck I’m afraid. However, I have stripped the whole thing back, and managed to get it to work to an extent:

    <?php 
    $cat = get_category( get_query_var( 'cat' ) );
    $category = $cat->slug;
    echo do_shortcode('[ajax_load_more category="'.$category.'" post_type="products" posts_per_page="12" orderby="menu_order" category__not_in="14,18"]');
    ?>

    However, I think order="ASC" combined with orderby="menu_order" is causing the issue. As soon as I try this, it throws it out. Even if it’s just orderby="menu_order" and order, with nothing else. However, using orderby="title" for example, along with order, works fine.

    Plugin Author Darren Cooney

    (@dcooney)

    I asked this above but not sure if you seen it…

    Are you using a plugin for ordering items in the WP Admin?

    Thread Starter unexploded

    (@unexploded)

    Hi sorry, been real busy. There are no plugins installed for ordering items.

    I’ve been racking my brains on this one and just cannot figure it out. I even tried order="asc" last night, and it WORKED!! However, it’s stopped working this afternoon. It’s like, it sometimes works, then it just gives up.

    Thread Starter unexploded

    (@unexploded)

    Also, there’s still the issue of some products not displaying. There could be 80-odd items, but it only displays 40-odd.

    Plugin Author Darren Cooney

    (@dcooney)

    No worries – I haven’t been able to replicate your issue so I’m just not sure at this point.

    Also, there’s still the issue of some products not displaying. There could be 80-odd items, but it only displays 40-odd.

    You need to set max_pages="0" in your shortcode.

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Menu_order issues’ is closed to new replies.