VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: razor7 on March 15, 2012, 16:18:39 PM

Title: Fatal error: Unsupported operand types in currency converter plugin
Post by: razor7 on March 15, 2012, 16:18:39 PM
Hi, I'm using VM 2.0.2 and Joomla 1.5.25

When trying to view the cart and adding discounted price products, the currency converter plugins get a price value not int, nor float, it gets an array!

the function that fails to pass the price as number and not as an array is "convertCurrencyTo" located in "currencyDisplay.php"

Quotearray
  0 =>
    array
      0 => string 'Discount for all Hand Tools' (length=27)
      1 => string '2.0000' (length=6)
      2 => string '-' (length=1)
      3 => string '1' (length=1)

array
  0 =>
    array
      0 => string 'Tax 9.25%' (length=9)
      1 => string '9.2500' (length=6)
      2 => string '+%' (length=2)
      3 => string '1' (length=1)
  1 =>
    array
      0 => string 'Duty for Powertools' (length=19)
      1 => string '20.0000' (length=7)
      2 => string '+%' (length=2)
      3 => string '1' (length=1)

Why is this happening, the currency convertion plugin obviously fails because receives an array instead a numeric value!

Best regards!