Support » Plugin: WooCommerce » next\previous product

  • Hello!
    I try to add next\previous groupped product links on the product page.
    I use this code and it works.

    add_action( ‘woocommerce_before_single_product’, ‘woocommerce_productnav’);
    function woocommerce_productnav() {
    <div class=”post-nav fix”>
    <span class=”previous”><?php previous_post_link($format=’&laquo %link’, $excluded_categories = ‘alchemia,east,earth,teeth,kingdome,bowl,beavers’); ?></span>
    <span class=”next”><?php next_post_link($format=’&laquo %link’, $excluded_categories = ‘alchemia,east,earth,teeth,kingdome,bowl,beavers’); ?></span>

    But in the link text all excluded categories are displayed.

    And then I add link text in the same code, for example:

    <span class=”previous”><?php previous_post_link($format=’&laquo %link’, ‘Previous’, $excluded_categories = ‘alchemia,east,earth,teeth,kingdome,bowl,beavers’); ?></span>

    Then my link disappears.
    How to set up the linked text?

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘next\previous product’ is closed to new replies.