NYCPHP Meetup

NYPHP.org

[joomla] Is this a php issue?

Donna Marie Vincent donnamarievincent at yahoo.com
Sun Jun 15 15:16:27 EDT 2008


I was having a problem with Virtuemart's Latest Products module.  It was stripping the dollar sign as well as the dollar amount, and showing just the decimal point and cents.

After spending the day (!) debugging this, I finally found the problem.

In class_currency_display.php, in the function getFullValue, in the assignment of $res, where the current var values are $res = 10.99 and $this->symbol = "$":

[code]$res=$this->symbol.$res;[/code]

for some reason $res ends up being ".99", missing the $ as well as the "10".  (It should have read "$10.99")

When I changed the code to read:

[code]$res = $this->symbol . " " . $res;[/code]

it now displays correctly as "$10.99".

Is this a problem with my php version or the php settings on the server?



More information about the Joomla mailing list