WP Order Cart
Sorted article list? (2 posts)

  1. bertholdsson
    Posted 2 years ago #

    Is there a way to sort the article list, either by article number (SKU) är article name.

    Either in an update of the plugin or a php-hack will be great :-)



  2. lanisanethong
    Posted 1 year ago #

    This solution worked for me for products displayed in the archive page...

    Under wp-order-cart/templates/products.php, go to ~line 33 where this code is:
    <?php if (have_posts()) : while (have_posts()) : the_post();?>

    Above that line, add this code:
    <?php query_posts($query_string . '&orderby=title&order=ASC'); ?>

    I have it sorted by title, but you should be able to change it to another field. Also, be aware that this will be overwritten if you update the plug-in.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic