Skip to content
Docs
Get RestroPress

Filter

rpress_cart_quantity_item

Updated
On this page

Filters the add-on list HTML shown under a cart item.

Runs at the end of get_addon_item_formatted(), which builds the list of selected add-ons with their prices for a cart line. It is empty when the line has no add-ons.

Parameters#

ParameterTypeDescription
$htmlstringAdd-on list markup.
$addon_itemsarrayThe cart line data holding the add-on items.

Return value#

string. The add-on list HTML.

Example#

function my_cart_addon_list( $html, $addon_items ) {
	return $html;
}
add_filter( 'rpress_cart_quantity_item', 'my_cart_addon_list', 10, 2 );

Source#

Applied in:

  • includes/cart/template.php (line 203), in get_addon_item_formatted()

See also#

Was this page helpful?