Properties

$args

$args :

Type

Methods

register()

register()

get_stock_html()

get_stock_html(  $html,  $product = false)

Parameters

$html
$product

get_stock_html_legacy()

get_stock_html_legacy(  $html,  $availability = false,  $product = false)

Parameters

$html
$availability
$product

loop_add_to_cart_args()

loop_add_to_cart_args(  $args)

Parameters

$args

add_to_cart_form_action()

add_to_cart_form_action(string  $url): string

Return a blank action for add to cart forms in the product table. This allows any non-AJAX actions to return back to the current page.

Parameters

string $url

Returns

string —

The URL

remove_image_srcset()

remove_image_srcset(  $attr)

Parameters

$attr

variations_dropdown_set_variation_image_props()

variations_dropdown_set_variation_image_props(  $variation_data,  $product,  $variation)

Parameters

$variation_data
$product
$variation

format_price_for_variable_products()

format_price_for_variable_products(  $price_html,  $product)

Parameters

$price_html
$product

product_addons_reset_display_hooks()

product_addons_reset_display_hooks()

load_product_addons_template()

load_product_addons_template(  $located,  $template_name,  $args,  $template_path,  $default_path)

Load any custom templates for WooCommerce Product Addons. Templates are located under /templates/addons/

Parameters

$located
$template_name
$args
$template_path
$default_path

product_addons_show_totals()

product_addons_show_totals()

simple_product_button_open_wrapper()

simple_product_button_open_wrapper()

simple_product_button_close_wrapper()

simple_product_button_close_wrapper()

before_add_to_cart_button()

before_add_to_cart_button()

after_add_to_cart_button()

after_add_to_cart_button()

variations_separate_remove_filtered()

variations_separate_remove_filtered(\Barn2\Plugin\WC_Product_Table\type  $child_ids,\Barn2\Plugin\WC_Product_Table\type  $product = false,\Barn2\Plugin\WC_Product_Table\type  $visible_only = false): \Barn2\Plugin\WC_Product_Table\type

When using separate variation rows with the layered nav widgets, we need to filter out variations which don't match the current search criteria.

Parameters

\Barn2\Plugin\WC_Product_Table\type $child_ids
\Barn2\Plugin\WC_Product_Table\type $product
\Barn2\Plugin\WC_Product_Table\type $visible_only

Returns

\Barn2\Plugin\WC_Product_Table\type

set_external_product_button_text()

set_external_product_button_text(  $button_text,  $product)

Parameters

$button_text
$product

set_quantity_input_args()

set_quantity_input_args(  $args,  $product)

Parameters

$args
$product

woocommerce_single_variation()

woocommerce_single_variation()

woocommerce_variable_add_to_cart()

woocommerce_variable_add_to_cart()

The add to cart template for variable products.

woocommerce_variation_add_to_cart()

woocommerce_variation_add_to_cart()

get_selected_variations_from_filters()

get_selected_variations_from_filters(  $variation_attributes)

Parameters

$variation_attributes