public function onPrepareCartItemDetails(string &$details, VAPCartItem $item) : void

Fires before displaying the details of a cart item.


Description

Trigger hook to manipulate the description of the item that is displayed within the summary cart. The description is shown within the confirmation page and within the cart widget. 


Parameters

&$details

(string)  The current item description.

$item

(VAPCartItem)  The instance of the cart item.

Return Value

None.


Example

/**
 * Trigger hook to manipulate the description of the item that is displayed
 * within the summary cart.
 *
 * @param   string       &$details  The description to show.
 * @param   VAPCartItem  $item      The item instance.
 *
 * @return  void
 */
public function onPrepareCartItemDetails(&$details, $item)
{
    $details .= '<p>This is an additional text to display.</p>';
}

Changelog

VersionDescription
1.7 Introduced.
Last Update: 2021-10-06 16:38
Helpful?
This site uses cookies. By continuing to browse you accept their use. Further information