Change Wishlist Button to Default - by kw13

1 reply2 participantsUpdated by Olga Barlow

Full guideWooCommerce wishlist: add, set up or remove it
  • Avatar: kw13
    kw13
    Participant

    Hi,

    I’d like the wishlist button to display next to “Add to Cart” which is the default for the YITH Wishlist plugin (a square button with heart inside it): https://docs.yithemes.com/yith-woocommerce-wishlist/free-settings/getting-started-free-version-plugin/

    How can I change or override where Royal shows this button so it defaults to YITH settings?

    Please, contact administrator
    for this information.

    1 Answer

    Avatar: Olga Barlow
    Olga Barlow
    Participant

    Hello,

    1) If you want to use the button instead of simple text + icon go to Wishlist > Colors > http://prntscr.com/mui059 edit the options according to your needs: enable icon, change the bg color, add the border. Add the following styles to child theme style.css to remove our default wishlist icon

    .product-information .yith-wcwl-add-to-wishlist a:before {content: "";}
    .product-information .yith-wcwl-add-to-wishlist a:before {background:none;}
    .product-information .cart button[type="submit"] {float: left;}

    2) Image in the plugin description is wrong because if you check their demo https://plugins.yithemes.com/yith-woocommerce-wishlist/product/yith-bag-roger/ you’ll see that add to wishlist button is located below the Add to cart button and even out of the Add to cart block http://prntscr.com/muhze2 You can enable even default theme, Storefront for example.
    If you want to place wishlist next to Add to cart button got to Wishlist > Settings > Position > Use shortcode. After that add the following code to child theme functions.php

    add_action( 'woocommerce_after_add_to_cart_button', 'et_custom_action', 5 );
    function et_custom_action() {
    echo do_shortcode('[yith_wcwl_add_to_wishlist]');
    }

    Regards

Want to reply? Log in, or register with your ThemeForest purchase code, to reply to this topic.

Login / Register