woocommerce_cart_item_product_id

woocommerce_cart_item_product_id

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.8.7.0

apply_filters('woocommerce_cart_item_product_id') is found 2 times:

  • /templates/cart/cart.php line 42
     
    			<?php
    			foreach ( WC()->cart->get_cart() as $cart_item_key => $cart_item ) {
    				$_product   = apply_filters( 'woocommerce_cart_item_product', $cart_item['data'], $cart_item, $cart_item_key );
    				$product_id = apply_filters( 'woocommerce_cart_item_product_id', $cart_item['product_id'], $cart_item, $cart_item_key );
    				/**
    				 * Filter the product name.
    				 *
    				 * @since 2.1.0
    				 * @param string $product_name Name of the product in the cart.
    				 * @param array $cart_item The product in the cart.
    
  • /templates/cart/mini-cart.php line 32
    		do_action( 'woocommerce_before_mini_cart_contents' );
    
    		foreach ( WC()->cart->get_cart() as $cart_item_key => $cart_item ) {
    			$_product   = apply_filters( 'woocommerce_cart_item_product', $cart_item['data'], $cart_item, $cart_item_key );
    			$product_id = apply_filters( 'woocommerce_cart_item_product_id', $cart_item['product_id'], $cart_item, $cart_item_key );
    
    			if ( $_product && $_product->exists() && $cart_item['quantity'] > 0 && apply_filters( 'woocommerce_widget_cart_item_visible', true, $cart_item, $cart_item_key ) ) {
    				/**
    				 * This filter is documented in woocommerce/templates/cart/cart.php.
    				 *
    				 * @since 2.1.0