MadTechie Posted April 6, 2007 Share Posted April 6, 2007 I have a slight problem where whenever i enter a UK Pound Sign into the database it seams to convert to a £, i have no idea why the  is appearing i assume its the charset which is 'utf8_general_ci' has anyone come across this before ? anyideas how i can resolve it ? Quote Link to comment https://forums.phpfreaks.com/topic/45902-solved-uk-pound-charset/ Share on other sites More sharing options...
effigy Posted April 6, 2007 Share Posted April 6, 2007 That's the correct UTF-8 encoding; see pound. Make sure your output is UTF-8. Quote Link to comment https://forums.phpfreaks.com/topic/45902-solved-uk-pound-charset/#findComment-223022 Share on other sites More sharing options...
MadTechie Posted April 6, 2007 Author Share Posted April 6, 2007 humm that site states decimal: £ UTF-8 (c2, a3) £ now the £ is what i am getting, the system was outputting correctly when reading from another database.. i am kinda at a loss on how to resolve this.. Quote Link to comment https://forums.phpfreaks.com/topic/45902-solved-uk-pound-charset/#findComment-223068 Share on other sites More sharing options...
effigy Posted April 6, 2007 Share Posted April 6, 2007 What exactly is the problem? You're not getting a pound sign when pulling data out of the database? Are you connecting to the database properly? What about your META charset? Quote Link to comment https://forums.phpfreaks.com/topic/45902-solved-uk-pound-charset/#findComment-223114 Share on other sites More sharing options...
MadTechie Posted April 6, 2007 Author Share Posted April 6, 2007 I am storing data into the database, but when i pull the date back all the £ convet to £, i have view'd the data in the database via phpMyAdmin and they are being stored as £, i have also trid converting £ to '£' but then the database stores the data as "£" what i want, is for the data to be stored without the 'Â' if i do the following in phpMyAdmin UPDATE `myTable` SET `myField` = '£1.99'; all is fine.. also UPDATE `myTable` SET `myField` = '£1.99'; all works well FROM phpMyAdmin, But if i perform the exact same SQL statement from my own php program it updates to '£1.99' or '£1.99' the reason i believe its a SQL problem rather than a PHP problem is because i had this exact same problem a few weeks ago when i move my code to another server. the thing thats the biggest pain is after the move i fixed it by changing the charset from 'latin1_swedish_ci' to 'utf8_general_ci' <-- it think, i hope that makes sense.. Quote Link to comment https://forums.phpfreaks.com/topic/45902-solved-uk-pound-charset/#findComment-223139 Share on other sites More sharing options...
MadTechie Posted April 6, 2007 Author Share Posted April 6, 2007 Oh and the input is from a form <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> Quote Link to comment https://forums.phpfreaks.com/topic/45902-solved-uk-pound-charset/#findComment-223178 Share on other sites More sharing options...
MadTechie Posted April 9, 2007 Author Share Posted April 9, 2007 Erm... I started to take at this problem today and its working!! I played with it last night with no luck.. but this morning its ok!!! ??? Quote Link to comment https://forums.phpfreaks.com/topic/45902-solved-uk-pound-charset/#findComment-224791 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.