News:

Looking for documentation? Take a look on our wiki

Main Menu

3.0.18.5: "We send to" error

Started by ClaudioRomeo, November 24, 2016, 08:56:32 AM

Previous topic - Next topic

ClaudioRomeo

J 3.6.4
VM 3.0.18.5
PHP     5.5.37

After the update to VM 3.0.18.5, the product details page doesn't show the countries where the shop delivers any longer.
Near the price there is now a generic string "Array".
I'm the author of the VirtueMart 3 Reference Guide
https://www.virtuemartmatters.com

Milbo

Which shipment plugin do you use? Reason could be that we changed in view productdetails, the default layout, this

if (is_array($this->productDisplayShipments)) {
  foreach ($this->productDisplayShipments as $productDisplayShipment) {
echo $productDisplayShipment . '<br />';
    }
}
if (is_array($this->productDisplayPayments)) {
    foreach ($this->productDisplayPayments as $productDisplayPayment) {
echo $productDisplayPayment . '<br />';
    }
}


to this

$productDisplayTypes = array('productDisplayShipments', 'productDisplayPayments');
foreach ($productDisplayTypes as $productDisplayType) {

if(empty($this->$productDisplayType)){
continue;
} else if (!is_array($this->$productDisplayType)) {
$this->$productDisplayType = array($this->$productDisplayType);
}

foreach ($this->$productDisplayType as $productDisplay) {

if(empty($productDisplay)){
continue;
} else if (!is_array($productDisplay)){
$productDisplay = array($productDisplay);
}

foreach ($productDisplay as $virtuemart_shipmentmethod_id =>$productDisplayHtml) {
?>
<div class="<?php echo substr($productDisplayType0, -1?> <?php echo substr($productDisplayType0, -1).'-'.$virtuemart_shipmentmethod_id ?>">
<?php
echo $productDisplayHtml;
?>

</div>
<?php
}
}
}
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

ClaudioRomeo

QuoteWhich shipment plugin do you use?
Weight Countries.

I'm not a developper, so I can't say anything about the code.
I'm the author of the VirtueMart 3 Reference Guide
https://www.virtuemartmatters.com

Milbo

What happens, when you disable your template overridE?
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

ClaudioRomeo

It works well.
Thank you for the light, Milbo.
I'll fix my override.
I'm the author of the VirtueMart 3 Reference Guide
https://www.virtuemartmatters.com