Re: Encoding issue with £

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dave Goodchild wrote:
> This may be more of a mysql issue, but I am using php for my app so here
> goes...
> 
> I have a fee field in the database, and when users post events they can
> specify entrance fee in £. In some, not all, of the fields I am getting,
> for
> example, £7 rather than £. Is this an encoding issue?
> 
> Many thanks in advance...
> 

as a sidenote (won't help to fix the current encoding issues outright):

currency values should be stored in the DB as integers (i.e. as penny based values).
no floats (so that you avoid any rounding errors) and definitely no currency symbols!

(if you need to store which currency the
price/ammount is in then use a seperate field (and don't use the symbol, instead use the currency
ISO code - many currencies share a common symbol!)

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux