Problem inserting german special Chracters - 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: Problem inserting german special Chracters (/showthread.php?tid=20901) Pages:
1
2
|
Problem inserting german special Chracters - El Forum - 07-24-2009 [eluser]breastfed[/eluser] Hello i am trying to add german Chars like ÄÖÜ or ß in the Database by a webbased Form. I think the Collations are set right, you can see them in the Screenshots of php Myadmin and the database.php. The Table i am working on is "jobs". What am i doing wrong? Thank you guys! Problem inserting german special Chracters - El Forum - 07-24-2009 [eluser]davidbehler[/eluser] What exactly is the problem? They aren't displayed correctly Try adding this to your website: Code: <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> Offtopic: Hallo von Deutschland nach Deutschland Problem inserting german special Chracters - El Forum - 07-24-2009 [eluser]breastfed[/eluser] Hello Waldmeister, i already have this charset in my HTML Template. Already the Database with PHPmyAdmin is showing "M?nster" instead of "Münster". Du Deutscher du... Problem inserting german special Chracters - El Forum - 07-24-2009 [eluser]davidbehler[/eluser] What happens if you enter those characters in your phpmyadmin directly? Does that work? And try adding this to your form tag Code: accept-charset="utf8" Problem inserting german special Chracters - El Forum - 07-24-2009 [eluser]breastfed[/eluser] I am using: <?php echo form_open($this->uri->uri_string())?> for the Form. Adding an "ü" inside of PHPmyAdmin works fine. Problem inserting german special Chracters - El Forum - 07-24-2009 [eluser]davidbehler[/eluser] try Code: <?php echo form_open($this->uri->uri_string(), array("accept-charset" => "utf8"))?> Problem inserting german special Chracters - El Forum - 07-27-2009 [eluser]breastfed[/eluser] Now i have ä,ü and ö in the Database, but they are not displayed correctly on the Website. But i added "utf-8" as the Charset. What might be wrong? THanks! Problem inserting german special Chracters - El Forum - 07-27-2009 [eluser]davidbehler[/eluser] Do you have an online example of your problem? Problem inserting german special Chracters - El Forum - 07-27-2009 [eluser]Phil Sturgeon[/eluser] You need to set UTF-8 on the connection, the table and varchar/text fields. Also, I always use utf8_unicode_ci and it never gives me any problems. Problem inserting german special Chracters - El Forum - 07-27-2009 [eluser]davidbehler[/eluser] The problem lies with his apache server. Its default char set seems to be set to "ISO-8859-1" instead of utf-8 and therefore overwrites the content-type. He might be able to fix this by editing the apache config or adding this right before loading the view: Code: header('Content-type: text/html; charset=utf-8'); |