Text input not being processed properly! - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Text input not being processed properly! (/showthread.php?tid=29859) Pages:
1
2
|
Text input not being processed properly! - El Forum - 05-01-2010 [eluser]Tominator[/eluser] 1. in HTML: Code: <meta http-equiv="content-type" content="text/html; charset=utf-8"> 3. set your DB/table/fields to UTF-8 4. doesn't work? try: Code: mysql_query("SET CHARACTER SET utf8"); Text input not being processed properly! - El Forum - 05-04-2010 [eluser]TheFuteballer[/eluser] [quote author="Tominator" date="1272724946"]1. in HTML: Code: <meta http-equiv="content-type" content="text/html; charset=utf-8"> 3. set your DB/table/fields to UTF-8 4. doesn't work? try: Code: mysql_query("SET CHARACTER SET utf8"); Thanks Tominator, a combination of all of these as well as other methods eventually fixed my issue. Just for anyones future reference, I set my DB to UTF8 charset and used the following script to convert all the tables and fields to UTF8, used step 4 above and then wrapped everythign in htmlentities function. Code: <?php Code: mysql_query("SET NAMES 'UTF8'"); Code: htmlentities($input, ENT_QUOTES, "UTF-8", FALSE), |