• Germanized
  • Hooks

Germanized Core

woocommerce_gzd_nutrient_types Filter

  1. $param array
add_filter( "woocommerce_gzd_nutrient_types", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_nutrient_rounding_rules Filter

  1. $param array
add_filter( "woocommerce_gzd_nutrient_rounding_rules", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_get_checkout_value Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_get_checkout_value", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_checkout_checkbox_is_checked Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_checkout_checkbox_is_checked", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_checkout_checkbox_is_visible Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_checkout_checkbox_is_visible", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_photovoltaic_cart_product_is_photovoltaic_accessory Filter

  1. $param_1 bool
  2. $param_2 string
add_filter( "woocommerce_gzd_photovoltaic_cart_product_is_photovoltaic_accessory", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_photovoltaic_systems_remove_zero_tax_class_for_non_exemptions Filter

  1. $param string
add_filter( "woocommerce_gzd_photovoltaic_systems_remove_zero_tax_class_for_non_exemptions", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_default_photovoltaic_systems_non_exemption_tax_class Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_default_photovoltaic_systems_non_exemption_tax_class", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_photovoltaic_systems_price_excludes_taxes_for_non_exemption Filter

  1. $param bool
add_filter( "woocommerce_gzd_photovoltaic_systems_price_excludes_taxes_for_non_exemption", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_disable_de_checkout_state_select Filter

  1. $param string
add_filter( "woocommerce_gzd_disable_de_checkout_state_select", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_autocorrect_address_1 Filter

  1. $param string
add_filter( "woocommerce_gzd_autocorrect_address_1", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_checkout_validate_street_number Filter

  1. $param_1 bool
  2. $param_2 string
add_filter( "woocommerce_gzd_checkout_validate_street_number", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_checkout_validate_billing_street_number Filter

  1. $param bool
add_filter( "woocommerce_gzd_checkout_validate_billing_street_number", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_checkout_is_valid_billing_street_number Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_checkout_is_valid_billing_street_number", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_checkout_invalid_billing_street_number_error_message Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_checkout_invalid_billing_street_number_error_message", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_checkout_is_valid_street_number Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_checkout_is_valid_street_number", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_checkout_invalid_street_number_error_message Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_checkout_invalid_street_number_error_message", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_parcel_delivery_order_opted_in Action

Parcel delivery notification. Execute whenever the parcel delivery notification data is stored for a certain order.

  1. $order_id int The order id.
  2. $selected bool True if the checkbox was checked. False otherwise.
add_action( "woocommerce_gzd_parcel_delivery_order_opted_in", function( $order_id, $selected ) {
    // Do something
        
}, 10, 2 );

woocommerce_gzd_photovoltaic_systems_opted_in Action

Customer has opted in to the photovoltaic systems‘ checkbox. Execute whenever a customer has opted in to the photovoltaic systems‘ checkbox.

  1. $order_id int The order id.
add_action( "woocommerce_gzd_photovoltaic_systems_opted_in", function( $order_id ) {
    // Do something
        
}, 10, 1 );

woocommerce_gzd_checkout_store_checkbox_data Action

  1. $param_1 string
  2. $param_2 string
add_action( "woocommerce_gzd_checkout_store_checkbox_data", function( $param_1, $param_2 ) {
    // Do something
        
}, 10, 2 );

woocommerce_gzd_enable_force_pay_order Filter

This filter is documented in includes/class-wc-gzd-checkout.php

  1. $param_1 bool
  2. $param_2 string
add_filter( "woocommerce_gzd_enable_force_pay_order", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_exclude_from_force_free_shipping Filter

Filter to exclude certain shipping rates from being hidden as soon as free shipping option is available.

  1. $is_excluded bool Whether the rate is excluded or not.
  2. $instance string The shipping rate instance.
  3. $rate \WC_Shipping_Rate The shipping rate.
add_filter( "woocommerce_gzd_exclude_from_force_free_shipping", function( $is_excluded, $instance, $rate ) {
    // Do something
    return $is_excluded;    
}, 10, 3 );

woocommerce_gzd_show_order_pay_now_button Filter

Filters whether to show the pay now button for a certain order. „`php function ex_show_order_button( $show, $order_id ) { if ( $order = wc_get_order( $order_id ) { // Check the order and decide whether to enable or disable button return false; } return $show; } add_filter( ‚woocommerce_gzd_show_order_pay_now_button‘, ‚ex_show_order_button‘, 10, 2 ); „`

  1. $enabled bool Whether to enable the button or not.
  2. $order_id int The order id.
add_filter( "woocommerce_gzd_show_order_pay_now_button", function( $enabled, $order_id ) {
    // Do something
    return $enabled;    
}, 10, 2 );

woocommerce_gzd_add_force_pay_order_parameter Filter

Filter whether to add the `force_pay_order` parameter to the URL to allow automatically redirecting the customer to the chosen payment provider after clicking the link.

  1. $enable bool Set to `false` to disable.
  2. $order_id int The order id.
add_filter( "woocommerce_gzd_add_force_pay_order_parameter", function( $enable, $order_id ) {
    // Do something
    return $enable;    
}, 10, 2 );

woocommerce_gzd_custom_checkout_admin_fields Filter

Filter to adjust custom checkout-related admin fields. This filter may be used to output certain checkout fields within admin order screen.

  1. $custom_fields array Array of fields.
  2. $checkout \WC_GZD_Checkout The checkout instance.
add_filter( "woocommerce_gzd_custom_checkout_admin_fields", function( $custom_fields, $checkout ) {
    // Do something
    return $custom_fields;    
}, 10, 2 );

woocommerce_gzd_custom_checkout_fields Filter

Filter to adjust custom checkout-related frontend fields. This filter may be used to output certain checkout fields within the checkout.

  1. $custom_fields array Array of fields.
  2. $checkout \WC_GZD_Checkout The checkout instance.
add_filter( "woocommerce_gzd_custom_checkout_fields", function( $custom_fields, $checkout ) {
    // Do something
    return $custom_fields;    
}, 10, 2 );

woocommerce_gzd_disable_custom_shipping_method_tax_calculation Filter

  1. $param_1 bool
  2. $param_2 string
add_filter( "woocommerce_gzd_disable_custom_shipping_method_tax_calculation", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_shipping_tax_shares Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_shipping_tax_shares", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_force_additional_costs_taxation Filter

Calculate split taxes if the cart contains more than one tax rate. Tax rounding (e.g. for subtotal) is handled by WC_Cart_Totals::get_shipping_from_cart

  1. $param bool
add_filter( "woocommerce_gzd_force_additional_costs_taxation", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_skip_fee_split_tax_calculation Filter

  1. $param_1 bool
  2. $param_2 string
add_filter( "woocommerce_gzd_skip_fee_split_tax_calculation", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_fee_tax_shares Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_fee_tax_shares", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_fee_costs_include_tax Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_fee_costs_include_tax", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_get_term Action

Before retrieving a certain term. Executes before retrieving a certain term (e.g. a delivery time).

  1. $key string The identifier e.g. term slug.
  2. $by string Indicates how to identify the term e.g. by slug.
  3. $taxonomy string The taxonomy linked to the term e.g. delivery_time.
add_action( "woocommerce_gzd_get_term", function( $key, $by, $taxonomy ) {
    // Do something
        
}, 10, 3 );

woocommerce_gzd_after_get_term Action

After retrieving a certain term. Executes after retrieving a certain term (e.g. a delivery time).

  1. $key string The identifier e.g. term slug.
  2. $by string Indicates how to identify the term e.g. by slug.
  3. $taxonomy string The taxonomy linked to the term e.g. delivery_time.
add_action( "woocommerce_gzd_after_get_term", function( $key, $by, $taxonomy ) {
    // Do something
        
}, 10, 3 );

woocommerce_gzd_get_product_{$prop} Filter

Filter to adjust a certain product property e.g. unit_price. The dynamic portion of the hook name, `$prop` refers to the product property e.g. unit_price.

  1. $value mixed The property value.
  2. $gzd_product \WC_GZD_Product The GZD product instance.
  3. $product \WC_Product The product instance.
  4. $context string

woocommerce_gzd_get_product_nutrients Filter

  1. $param_1 array
  2. $param_2 string
  3. $param_3 string
add_filter( "woocommerce_gzd_get_product_nutrients", function( $param_1, $param_2, $param_3 ) {
    // Do something
    return $param_1;    
}, 10, 3 );

woocommerce_gzd_get_product_nutrients_html Filter

  1. $param_1 string
  2. $param_2 string
  3. $param_3 string
add_filter( "woocommerce_gzd_get_product_nutrients_html", function( $param_1, $param_2, $param_3 ) {
    // Do something
    return $param_1;    
}, 10, 3 );

woocommerce_gzd_get_product_allergenic Filter

  1. $param_1 array
  2. $param_2 string
  3. $param_3 string
add_filter( "woocommerce_gzd_get_product_allergenic", function( $param_1, $param_2, $param_3 ) {
    // Do something
    return $param_1;    
}, 10, 3 );

woocommerce_gzd_get_product_formatted_allergenic Filter

  1. $param_1 string
  2. $param_2 string
  3. $param_3 string
add_filter( "woocommerce_gzd_get_product_formatted_allergenic", function( $param_1, $param_2, $param_3 ) {
    // Do something
    return $param_1;    
}, 10, 3 );

woocommerce_gzd_product_formatted_nutri_score Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_formatted_nutri_score", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_product_power_supply_html Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_power_supply_html", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_product_net_filling_quantity_unit Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_net_filling_quantity_unit", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_product_formatted_net_filling_quantity Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_formatted_net_filling_quantity", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_drain_weight_unit Filter

  1. $param string
add_filter( "woocommerce_gzd_drain_weight_unit", function( $param ) {
    // Do something
    return $param;    
}, 10, 1 );

woocommerce_gzd_product_formatted_drain_weight Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_formatted_drain_weight", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_product_includes_alcohol Filter

  1. $param_1 string
  2. $param_2 string
  3. $param_3 string
add_filter( "woocommerce_gzd_product_includes_alcohol", function( $param_1, $param_2, $param_3 ) {
    // Do something
    return $param_1;    
}, 10, 3 );

woocommerce_gzd_product_manufacturer Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_manufacturer", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_product_get_main_brand_for_manufacturer Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_get_main_brand_for_manufacturer", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_product_has_safety_information Filter

  1. $param_1 string
  2. $param_2 string
add_filter( "woocommerce_gzd_product_has_safety_information", function( $param_1, $param_2 ) {
    // Do something
    return $param_1;    
}, 10, 2 );

woocommerce_gzd_product_manufacturer_html Filter

Filter to adjust product manufacturer html output.

  1. $html string The product manufacturer html.
  2. $product \WC_GZD_Product The product object.
add_filter( "woocommerce_gzd_product_manufacturer_html", function( $html, $product ) {
    // Do something
    return $html;    
}, 10, 2 );