How can I change this that it opens in a new web browser tab?
]]>We read the documentation based on github but do not know how to autneticate using rest API functionality. Do anyone know how to do so? Or ist the plugin only acessable via functionallity within the wordpress page?
Best regards
mhasli
]]>This functionality works seamlessly on category pages and WooCommerce short pages. However, it’s not functioning as expected with WooCommerce product blocks in Gutenberg.
I’ve searched around for solutions but haven’t found any previous discussions on this topic. Could you please assist me in adapting this code to work with product blocks in Gutenberg?
// Remove the default action that adds the product link
add_action('init', function () {
remove_action('woocommerce_before_shop_loop_item', 'woocommerce_template_loop_product_link_open');
});
// Add a custom action to generate the external product link
add_action('woocommerce_before_shop_loop_item', function () {
global $product;
// Check if the product is external
if ($product->is_type('external')) {
// Get the external product URL
$external_url = $product->get_product_url();
// Output the external product link
echo '<a href="' . $external_url . '">';
} else {
// Output the regular product link
woocommerce_template_loop_product_link_open();
}
}, 20);
]]>The goal is to have a link (button) on each product page, opening a contact page, with a unique contact form. And to have automaticaly, the object filled with the original product page name. (witch is in the button link)
Thanks for your help
]]>Plz help, thx!
]]>Since this functionality doesn’t appear to exist currently in the latest version of woocommerce 8.1.1, I’d like to know if there is an alternative method that can be used?
I need to be able to import Amazon products as variations and have the woocommerce product be updated automatically with my Amazon affiliate id and ensure the ‘buy’ button is the amazon link with affiliate tag.
]]>And is it possible to use the links that have been created elsewhere, or only on the website itself?
]]>