添加到购物车之后,出现了UNABLE TO SAVE UPDATE QUANTITY提示错误
There is a problem with adding/removing (using + or -) products from the basket. It gives the following error:
TECHNICAL ERROR: unable to save update quantity
Details:
Error thrown: [object XMLHttpRequest]
Text status: error
The solution: add in the CartController.php class
public $ssl = true;
The problem happens, because the Cart Controller doesn’t have this ssl=true and it redrect to http:// and it cause the error.
My current solution is to extend that controller and add this $ssl=true in it.
修改classes目录下的FrontController.php文件以下内容。
在public function init()下
self::$initialized=true;后添加
if(Tools::usingSecureMode())
$useSSL =$this->ssl = true;
把else if (Configuration::get(‘PS_SSL_ENABLED’) AND Tools::usingSecureMode() AND !($this->ssl) )
修改为
else if (Configuration::get(‘PS_SSL_ENABLED’) AND Tools::usingSecureMode() AND !($this->ssl) AND $_POST == array())
测试后方可正常使用。