Problems with accents and special characters - 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: Problems with accents and special characters (/showthread.php?tid=9857) |
Problems with accents and special characters - El Forum - 07-10-2008 [eluser]marcoss[/eluser] htmlentities will convert all applicable characters to HTML entities, it WILL NOT do character encoding/decoding, the reason it exists is to translate spacial character to their corresponding HTML entities. However, it may work sometimes as you point, but that is because the function accepts a third parameter ($charset) which if not specified, will default to ISO-8859-1, so the output is returned that way (forced). Problems with accents and special characters - El Forum - 07-11-2008 [eluser]CARP[/eluser] Seppo I can't htmlentity automatically the user input in my forms... can I ? Congrats for your 700th post Also, found this "fix" but didn't work... I'm so frustrated http://www.lorztech.com/2008/06/unable-to-set-database-connection.html ============ Edit: I've found this interesting article http://www.davidtan.org/differences-between-utf8_unicode_ci-and-utf8_general_ci/ I got astoonished when I read: Quote:utf8_general_ci is a very simple collation. What it does - it just But changing the values in database.php, and tables to another collation, don't work Problems with accents and special characters - El Forum - 07-11-2008 [eluser]CARP[/eluser] Guys I've seen something that may be the cause of all this conflicts... am i right? Check: http://img154.imageshack.us/img154/7966/sshot1bs9.jpg Also, doing this in dreamweaver for the header_view.php file (Ctrl+J, go to Title/Encoding and select Unicode(UTF-8) from the encoding drop-down menu.) helped, but - How do I know if my .php source file is in UTF-8 ? - Does this assure me that uploading the entire application/db will work on any shared hosting ? Thanks a lot again... Problems with accents and special characters - El Forum - 10-13-2008 [eluser]Asinox[/eluser] ok, yo no soy argentino.... pero tengo el mismo problema... Problems with accents and special characters - El Forum - 11-01-2008 [eluser]Asinox[/eluser] ok i fixed!. Entonces las unicas cosas que tuve que hacer: DB Collation: utf8_general_ci <html lang="es"> y claro <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> Saludos Problems with accents and special characters - El Forum - 12-08-2008 [eluser]Unknown[/eluser] Hola, estoy teniendo el problema de los acentos, tengo dos versiones de CI , la 1.3 y la 1.7 y en la v1.3 no encuentro como poner a funcionar los acentos , hice el asunto de modificar el header y nada . Problems with accents and special characters - El Forum - 12-08-2008 [eluser]Asinox[/eluser] Hola, estoy fue lo que yo hice (en mis vistas y en la base de datos) Entonces las unicas cosas que tuve que hacer: En la base de datos: DB Collation: utf8_general_ci en la vista: <html lang=“es”> <meta http-equiv=“Content-Type” content=“text/html; charset=utf-8” /> Saludos Problems with accents and special characters - El Forum - 01-25-2009 [eluser]Andres Ledesma[/eluser] Hello guys! just for the record, I'm working with Spanish especial chars, and this is what I did to get it rollin. Change the values in the database.php inside your config folder like these: $db['default']['char_set'] = "latin1"; $db['default']['dbcollat'] = "latin1_swedish_ci"; Then just make sure that the collation of your attributes in your db are "latin1_swedish_ci". And that is all! Hope this helps someone! Cheers! Problems with accents and special characters - El Forum - 01-25-2009 [eluser]Asinox[/eluser] [quote author="Andres Ledesma" date="1232947351"]Hello guys! just for the record, I'm working with Spanish especial chars, and this is what I did to get it rollin. Change the values in the database.php inside your config folder like these: $db['default']['char_set'] = "latin1"; $db['default']['dbcollat'] = "latin1_swedish_ci"; Then just make sure that the collation of your attributes in your db are "latin1_swedish_ci". And that is all! Hope this helps someone! Cheers! [/quote] Im sorry Andres but the real thing is: $db['default']['char_set'] = "utf8"; $db['default']['dbcollat'] = "utf8_general_ci"; All chars Problems with accents and special characters - El Forum - 01-25-2009 [eluser]Andres Ledesma[/eluser] Well, I used "latin1" as char_set and "latin1_swedish_ci" as coll, and the accents and "ñ" worked like a charm. |