WordPress action hook
woocommerce_before_cart_collaterals
Defined by WooCommerce and fired by 26 plugins in total, running on 8.6M+ sites between them.
How to use woocommerce_before_cart_collaterals
It's an action: your callback runs at that point. Nothing needs to be returned.
Add this to your theme's functions.php or a small custom plugin:
add_action( 'woocommerce_before_cart_collaterals', function() {
// Your code runs here.
}, 10, 1 );Argument names come from WooCommerce's source. Other plugins may pass different values: check the call in the plugin you're targeting below.
26 plugins that fire woocommerce_before_cart_collaterals
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
WooCommerce7+ million installs
do_action( 'woocommerce_before_cart_collaterals' )templates/cart/cart.php:221 -
Essential Addons for Elementor1+ million installs
do_action( 'woocommerce_before_cart_collaterals' )includes/Template/Woocommerce/Cart/Woo_Cart_Helper.php:703 -
Royal Addons for Elementor600,000+ installs
do_action( 'woocommerce_before_cart_collaterals' )includes/woocommerce/templates/cart/cart.php:163 -
CoDesigner4,000+ installs
do_action( 'woocommerce_before_cart_collaterals' )widgets/cart-items/cart-items.php:2187 -
WowStore4,000+ installs
do_action( 'woocommerce_before_cart_collaterals' )blocks/woo/cart_table/Template.php:278 -
Instantio700+ installs
do_action( 'woocommerce_before_cart_collaterals' )includes/templates/cart-modern.php:250 -
MarketKing700+ installs
do_action( 'woocommerce_before_cart_collaterals' )public/templates/cart.php:57 -
ShopPress600+ installs
do_action( 'woocommerce_before_cart_collaterals' )public/templates/cart/cart.php:16 -
StoreBuild400+ installs
do_action( 'woocommerce_before_cart_collaterals' )public/woocommerce/cart/cart.php:205 -
CRT Addons Builder and Widgets for Elementor300+ installs
do_action( 'woocommerce_before_cart_collaterals' )includes/customizer/addons/templates/cart/cart.php:163 -
Free Product Sample for WooCommerce200+ installs
do_action( 'woocommerce_before_cart_collaterals' )public/partials/woocommerce/cart/cart.php:166 -
KiriminAja Official200+ installs
do_action( 'woocommerce_before_cart_collaterals' )templates/woocommerce/cart/cart.php:195 -
Shopready100+ installs
do_action( 'woocommerce_before_cart_collaterals' )src/extension/templates/presets/cart/cart.php:654 -
ShopMaker90+ installs
do_action( 'woocommerce_before_cart_collaterals' )templates/widgets/sm-parts/cart-total.php:12 -
AMP WooCommerce90+ installs
do_action( 'woocommerce_before_cart_collaterals' )templates/cart/cart.php:179 -
Gift Vouchers for WooCommerce80+ installs
do_action( 'woocommerce_before_cart_collaterals' )templates/cart/cart.php:180 -
WebSync Checkout for Elementor60+ installs
do_action( 'woocommerce_before_cart_collaterals' )templates/cart/custom-cart.php:174 -
Elite Elementor Addons and Widgets20+ installs
do_action( 'woocommerce_before_cart_collaterals' )includes/woocommerce/templates/cart/cart.php:163 -
Max Elements for Elementor10+ installs
do_action( 'woocommerce_before_cart_collaterals' )elementor/helpers/woo_cart.php:659 -
Categorized Cart Page For Woocommerce10+ installs
do_action( 'woocommerce_before_cart_collaterals' )templates/cart.php:177 -
ACL10+ installs
do_action( 'woocommerce_before_cart_collaterals' )includes/cart/class-wooacd-cart-frontend.php:196 -
Formdev10+ installs
do_action( 'woocommerce_before_cart_collaterals' )templates/cart.php:292 -
Cresta Checkout for WooCommerceFewer than 10 installs
do_action( 'woocommerce_before_cart_collaterals' )templates/wc/cart/cart.php:20 -
PaymentIQ CheckoutFewer than 10 installs
do_action( 'woocommerce_before_cart_collaterals' )templates/paymentiq-cart-page.php:162 -
Portus Cart PageFewer than 10 installs
do_action( 'woocommerce_before_cart_collaterals' )templates/cart.php:73 -
SamplyFewer than 10 installs
do_action( 'woocommerce_before_cart_collaterals' )includes/Frontend/views/woocommerce/cart/cart.php:166
Need a customisation built on this hook?
Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.