market press re-ordering product listings

Given that product listings are effectively posts, how can I re-arrange the order in which they appear? With thanks, Andy

  • aecnu

    Greetings Andy,

    Welcome to WPMU Dev!

    You are not totally correct that product listings are effectively posts they are custom post types which is a different animal.

    Since you did not specify a Market Press compatible theme i.e. Frame Market/Grid Market etc.

    MarketPress uses custom post types to display it's products. This means that you can use the same WP theme template system you are familiar with. We simply provide a customized subset of template functions so you don't have to worry about dealing with post meta.

    Template functions are fully documented and can be found in the /marketpress/marketpress-includes/template-functions.php file.

    MarketPress searches your current theme folder for template files specific to store pages. If a template file does not exist it loads the theme's page template instead. Just like WP, the plugin will search for templates in order of priority from top to bottom. Here are possible file names for store templates in order:

    Single Product Page
    mp_product-PRODUCTNAME.php
    mp_product-PRODUCTID.php
    mp_product.php

    Store Page
    mp_store.php

    Cart/Checkout Page
    mp_cart.php

    Order Status Page
    mp_orderstatus.php

    Product List Page
    mp_productlist.php

    Product Category List Page
    mp_category-CATEGORYSLUG.php
    mp_category-CATEGORYID.php
    mp_category.php
    mp_taxonomy.php
    mp_productlist.php

    Product Tag List Page
    mp_tag-TAGSLUG.php
    mp_tag-TAGID.php
    mp_tag.php
    mp_taxonomy.php
    mp_productlist.php

    --------------------------------------------------
    Global Listings - Will only work on main site/blog
    --------------------------------------------------
    Product List Page
    mp_global_products.php
    mp_productlist.php

    Product Category List Page
    mp_global_category-CATEGORYSLUG.php
    mp_global_category.php
    mp_global_category_list.php

    Product Tag List Page
    mp_global_tag-TAGSLUG.php
    mp_global_tag.php
    mp_global_tag_list.php

    Then depending on how your built your site if using shortcodes, this is the shortcode below you want to use to arrange your products to include possible attributes:

    Products List [mp_list_products] - Displays a list of products according to preference. Optional attributes default to the values in Presentation Settings -> Product List.

    Optional Attributes:

    "paginate" - Whether to paginate the product list. This is useful to only show a subset.
    "page" - The page number to display in the product list if "paginate" is set to true.
    "per_page" - How many products to display in the product list if "paginate" is set to true.
    "order_by" - What field to order products by. Can be: title, date, ID, author, price, sales, rand (random).
    "order" - Direction to order products by. Can be: DESC, ASC
    "category" - Limits list to a specific product category. Use the category Slug
    "tag" - Limits list to a specific product tag. Use the tag Slug
    Example: [mp_list_products paginate="true" page="1" per_page="10" order_by="price" order="DESC" category="downloads"]

    Please advise if this is indeed the information you were seeking.

    Cheers, Joe

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.