News:

Looking for documentation? Take a look on our wiki

Main Menu

Error online 522 in this file: vmpsplugin.php

Started by simsar78, February 05, 2012, 11:36:34 AM

Previous topic - Next topic

simsar78

when i go to the cart i receveid this error in head of cart:

Warning: Invalid argument supplied for foreach() in /web/htdocs/www.xxx.xx/home/administrator/components/com_virtuemart/plugins/vmpsplugin.php on line 522

Warning: Invalid argument supplied for foreach() in /web/htdocs/www.xxx.xx/home/administrator/components/com_virtuemart/plugins/vmpsplugin.php on line 522

Warning: Invalid argument supplied for foreach() in /web/htdocs/www.xxx.xx/home/administrator/components/com_virtuemart/plugins/vmpsplugin.php on line 522

Warning: Invalid argument supplied for foreach() in /web/htdocs/www.xxx.xx/home/administrator/components/com_virtuemart/plugins/vmpsplugin.php on line 522

I use J1.5.25 and 1.7 whit virtuemart 2.0.1.d

Thanks

EDIT:  I have this problem only whit j 1.5.25

p.barg

Yes, I get the same warnings with j1.5x and VM 2.0.1.d

flo31

#2
Try replace in /administrator/components/com_virtuemart/plugins/vmpsplugin.php on line 522

Replace :

foreach ($this->methods as $method) {
    VmTable::bindParameterable($method, $this->_xParams, $this->_varsToPushParam);
}



By :
if (count($this->methods) ! = 0 ) {
  foreach ($this->methods as $method) {
VmTable::bindParameterable($method, $this->_xParams, $this->_varsToPushParam);
}
}



Or if you configure a shipment and payment method I think the warning won't appear anymore.

p.barg

I do have shipment and payment methods defined...