Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save michaeltieso/9794479 to your computer and use it in GitHub Desktop.
Save michaeltieso/9794479 to your computer and use it in GitHub Desktop.
Posted below is what you will need to add to your themes function.php to disable nRelate on WooCommerce's pages.
function hide_nrelate_from_posts($load_nrelate) {
if ( is_woocommerce() ) {
$load_nrelate = false;
}
return $load_nrelate;
}
add_filter('nrelate_related_is_loading', 'hide_nrelate_from_posts');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment