In my database I keep width and height as float numbers. These measures
have sometimes decimal places and sometimes not.
I know that with number_format($mynumber,2,'.',' ') for example I can
determine the number of decimal places, etc, etc.
The problem is that I want to show the format with '.' or ',' depending
on the language but not a fix number of decimals. For example:
34,50 should be 34,50 or 34.50 depending on the language... and
33 should be 33 ... I don't want that it will be shown as 33,00 or
33.00.
Is there a way to combine the possibility of change between '.' and ','
and also varying the number of decimal places?
Thanks in advance.
Bettina