Tagged: avia post nav, woocommerce
Hallo, ich möchte gerne (wenn möglich) die Funktion “Post Nav” in einer bestimmten Produktkategorie (Woocommerce) nutzen. Also vor und zurück “nur” in einer Kategorie. Aktuell springt es (wohl) nach Datum.
#####
Hello, I would like to use (if possible) the function “Post Nav” in a specific product category of Woocommerce. So back and forth “only” in one category. Currently it jumps (probably) by date.
Hi Maurice,
Please add this code at the bottom of your child theme’s functions.php:
function enfold_post_nav_settings($settings)
{
if($settings['type'] == 'product')
{
$settings['taxonomy'] = "product_cat";
$settings['same_category'] = true;
}
return $settings;
}
add_filter( 'avf_post_nav_settings', 'enfold_post_nav_settings', 10, 2);
Hope it helps.
Best regards,
Nikko