Skip to content

Instantly share code, notes, and snippets.

@pablo-sg-pacheco
Last active June 20, 2018 18:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pablo-sg-pacheco/1caffffda20360ddf68e970c3b8dc71d to your computer and use it in GitHub Desktop.
Save pablo-sg-pacheco/1caffffda20360ddf68e970c3b8dc71d to your computer and use it in GitHub Desktop.
Add compatibility with WOOF plugin and More Sorting Options for WooCommerce regarding title sorting option
<?php
// Add these cases on get_catalog_orderby() function on index.php
case 'title-desc':
$orderby = "title";
$order = 'DESC';
break;
case 'title-asc':
$orderby = "title";
$order = 'ASC';
break;
@pablo-sg-pacheco
Copy link
Author

pablo-sg-pacheco commented Jun 20, 2018

More Sorting Options for WooCommerce


WOOF - Woocommerce Products Filter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment