LemonStand Documentation

shop:onOrderError event

The shop:onOrderError event is triggered if an order occurs during the order placement. This event is triggered only if the order is created from the front-end store pages. If you create an order from the Administration Area, the event is not triggered. The event handler should accept 2 parameters - the cart name and the error message string.

Event handler example:

public function subscribeEvents()
{
  Backend::$events->addEvent('shop:onOrderError', $this, 'process_order_error');
}
 
public function process_order_error($cart_name, $error_message)
{
  // Do something
}

Next: shop:onUpdateShippingQuote event
Previous: shop:onAfterProductFileAdded event
Return to Handling LemonStand events