Woocommerce open product link in new tab after "endless scroll" with ajax | بلاگ

Woocommerce open product link in new tab after "endless scroll" with ajax

تعرفه تبلیغات در سایت

آخرین مطالب

امکانات وب

Vote count: 0

I have managed to get all product links on my Woocommerce site to open in a new tab, however, I am using endless scroll with ajax for loading more products and the products that get loaded via ajax does not open in a new tab when clicking on them.

Here is my current code for opening products in a new tab;

remove_action( 'woocommerce_before_shop_loop_item','woocommerce_template_loop_product_link_open', 10 );
add_action ( 'woocommerce_before_shop_loop_item', 'chr_function_open_new_tab', 10 );
function chr_function_open_new_tab() {
echo '';
}

Any help with this is highly appreciated. Thanks in advance!

...
نویسنده : استخدام کار بازدید : 0 تاريخ : جمعه 23 شهريور 1397 ساعت: 12:24