Sunnysideup\Ecommerce\Api\ShoppingCart::setMessageAndReturn
This method is used to return data after an ajax call was made.
When a asynchronious request is made to the shopping cart (ajax), then you will first action the request and then use this function to return some values. It can also be used without ajax, in wich case it will redirects back to the last page. Note that you can set the ajax response class in the configuration file.
Signature
public function setMessageAndReturn([string
$message = '',
[string
$status = '',
[Form
$form = NULL]]] )
Parameters
Line | Task |
---|---|
1146 | handle passing back multiple messages |
1153 | handle passing a message back to a form->sessionMessage |