WPIntell

Source evidence

Do you have Shortcode for this plugin

Wishlist for WooCommerce · support · 2023-01-19T08:22:00+00:00

neutralsentiment
highseverity
0.69relevance
2replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

3 / 31 rows with source links

9.7% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

28 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
Abhishek resolved
Hello, I am using Elementor single product page and the wishlist button is not showing so can you tell me if this plugin has Shortcode. Thanks in advance. Never Mind I have find the solution on this thread. In case anyone needs it : add_shortcode( 'cus_wishlist_shortcode', 'woo_wishlist_shortcode_func' ); function woo_wishlist_shortcode_func() { if ( ! is_object( $product) ) { $product = wc_get_product( get_the_ID() ); $wt_wishlist = new WT_Wishlist_Singlepage(); $wt_wishlist->render_webtoffee_wishlist_button(); } } This reply was modified 3 years, 4 months ago by Abhishek . This reply was modified 3 years, 4 months ago by Abhishek . I’m using another block to work inside products loop, which also can be encapsulated into shortcode function. Just added some check to avoid crashing if plugin is inactive: if (in_array('wt-woocommerce-wishlist/wishlist-webtoffee.php', apply_filters('active_plugins', get_option('active_plugins')))){ $wt_wishlist = new WT_Wishlist_Looppage(); $wt_wishlist->render_webtoffee_wishlist_button(); } So, shortcode for “Add to wishlist” button, which you can place anywhere in a loop of product blocks will be like this: add_shortcode( 'cus_wishlist_loop_shortcode', 'woo_wishlist_loop_shortcode_func' ); function woo_wishlist_loop_shortcode_func() { if (in_array('wt-woocommerce-wishlist/wishlist-webtoffee.php', apply_filters('active_plugins', get_option('active_plugins')))){ $wt_wishlist = new WT_Wishlist_Looppage(); $wt_wishlist->render_webtoffee_wishlist_button(); } }

Comments

2 shown
Abhishek 2023-01-19T08:43:00+00:00

Never Mind I have find the solution on this thread. In case anyone needs it : add_shortcode( 'cus_wishlist_shortcode', 'woo_wishlist_shortcode_func' ); function woo_wishlist_shortcode_func() { if ( ! is_object( $product) ) { $product = wc_get_product( get_the_ID() ); $wt_wishlist = new WT_Wishlist_Singlepage(); $wt_wishlist->render_webtoffee_wishlist_button(); } } This reply was modified 3 years, 4 months ago by Abhishek . This reply was modified 3 years, 4 months ago by Abhishek .

xand79 2023-05-17T15:48:00+00:00

I’m using another block to work inside products loop, which also can be encapsulated into shortcode function. Just added some check to avoid crashing if plugin is inactive: if (in_array('wt-woocommerce-wishlist/wishlist-webtoffee.php', apply_filters('active_plugins', get_option('active_plugins')))){ $wt_wishlist = new WT_Wishlist_Looppage(); $wt_wishlist->render_webtoffee_wishlist_button(); } So, shortcode for “Add to wishlist” button, which you can place anywhere in a loop of product blocks will be like this: add_shortcode( 'cus_wishlist_loop_shortcode', 'woo_wishlist_loop_shortcode_func' ); function woo_wishlist_loop_shortcode_func() { if (in_array('wt-woocommerce-wishlist/wishlist-webtoffee.php', apply_filters('active_plugins', get_option('active_plugins')))){ $wt_wishlist = new WT_Wishlist_Looppage(); $wt_wishlist->render_webtoffee_wishlist_button(); } }