Add woocommerce_loop_product_link filter
This commit is contained in:
parent
eb60a17818
commit
0192fb9ef0
|
@ -778,7 +778,11 @@ if ( ! function_exists( 'woocommerce_template_loop_product_link_open' ) ) {
|
|||
* Insert the opening anchor tag for products in the loop.
|
||||
*/
|
||||
function woocommerce_template_loop_product_link_open() {
|
||||
echo '<a href="' . esc_url( get_the_permalink() ) . '" class="woocommerce-LoopProduct-link woocommerce-loop-product__link">';
|
||||
global $product;
|
||||
|
||||
$link = apply_filters( 'woocommerce_loop_product_link', get_the_permalink(), $product );
|
||||
|
||||
echo '<a href="' . esc_url( $link ) . '" class="woocommerce-LoopProduct-link woocommerce-loop-product__link">';
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue