Package Contents - Filter Hook References - Shipped

Package Contents - Filter Hook References

This is simply a list of package contents-related filter hooks found within the WooCommerce Table Rate Shipping files. This list also includes the supported parameters and example codes.


wtars_shipped/get-package-item

  • Parameters:
  • $package_item array()
  • $item array()

Example Codes:

  1. function custom_get_package_item( $package_item, $item ) {
  2.   //add your custom code here
  3.   return $package_item;
  4. }
  5. add_filter( 'wtars_shipped/get-package-item', 'custom_get_package_item', 10, 2 );

wtars_shipped/get-grouped-packages

  • Parameters:
  • $grouped_packages array()
  • $group_by array()
  • $data array()

Example Codes:

  1. function custom_get_grouped_packages( $grouped_packages, $group_by, $data ) {
  2.   //add your custom code here
  3.   return $grouped_packages;
  4. }
  5. add_filter( 'wtars_shipped/get-grouped-packages', 'custom_get_grouped_packages', 10, 3 );

wtars_shipped/get-package-destination

  • Parameters:
  • $package_destination array()
  • $package array()

Example Codes:

  1. function custom_get_package_destination( $package_destination, $package ) {
  2.   //add your custom code here
  3.   return $package_destination;
  4. }
  5. add_filter( 'wtars_shipped/get-package-destination', 'custom_get_package_destination', 10, 2 );
    • Related Articles

    • Shipping Costs / Shipping Fees - Filter Hook References

      This is simply a list of shipping costs/fees related filter hooks found within the WooCommerce Table Rate Shipping files. This list also includes the supported parameters and example codes. wtars_shipped_admin/get-cost-type-groups Parameters: ...
    • Shipping Rates - Filter Hook References

      This is simply a list of shipping rates-related filter hooks found within the WooCommerce Table Rate Shipping files. This list also includes the supported parameters and example codes. wtars_shipped/rate-cost Parameters: $rate_cost array() $rate_id ...
    • Cart Contents - Filter Hook References

      This is simply a list of cart contents-related filter hooks found within the WooCommerce Table Rate Shipping files. This list also includes the supported parameters and example codes. wtars_shipped/get-cart-item Parameters: $cart_item array() $item ...
    • Cart / Package Totals - Filter Hook References

      This is simply a list of cart/package totals-related filter hooks found within the WooCommerce Table Rate Shipping files. This list also includes the supported parameters and example codes. wtars_shipped_admin/get-totals-options Parameters: ...
    • Shipping Rates

      The Shipping Rates setting page can be used to create and manage shipping rates (i.e the shipping methods). Multiple shipping rates and shipping costs can be made available based on product rules and conditions. Cost Limit Per Rate This field ...