thanks for your reply
I tried this but didn’t work
and then found in https://ww.wp.xz.cn/support/topic/product-image-linked-to-external-url-with-relnofollow/
So far, I came to a solution in which I can redirect them to the affiliate external links adding this piece of code to functions.php:
add_action( ‘template_redirect’, ‘redirect_external_products’ );
function redirect_external_products() {
global $post;
if ( is_singular( ‘product’ ) && ! empty( $post ) && ( $product = wc_get_product( $post ) ) && $product->is_type( ‘external’ ) ) {
wp_redirect( $product->get_product_url() );
exit;
}
}
when I tried it it worked!
the only problem now is when we hover on the product it display in the footer tip the original product link and not the external link
if you have something to work around this I’d really appreciate it
thank you in advance
Note: I already tried to add the code mentioned here: https://ww.wp.xz.cn/support/topic/nimble-portfolio-not-in-dashboard/
but nothing happens!