woocommerce_get_remove_url
Gets the url to remove an item from the cart.
Использование
add_filter( 'woocommerce_get_remove_url', 'wp_kama_woocommerce_get_remove_url_filter' ); function wp_kama_woocommerce_get_remove_url_filter( $cart_item_key ){ // filter... return $cart_item_key; }
- $cart_item_key(строка)
- contains the id of the cart item.
Список изменений
С версии 3.3.0 | Введена. |
Где вызывается хук
woocommerce_get_remove_url
woocommerce/includes/wc-template-functions.php 3758
return apply_filters( 'woocommerce_get_remove_url', $cart_page_url ? wp_nonce_url( add_query_arg( 'remove_item', $cart_item_key, $cart_page_url ), 'woocommerce-cart' ) : '' );