I need to learn all these encoding stuffs well. Because this is the third time I'm wasting my time with silly wrong encoding problems. Here is the problem:
I have a simple php file.
- File is in the format of UTF-8
- If I run my local server, it makes
ı => ı
andö => Ü
- If I rename extension as HTML it works perfectly, so the problem is local server, definetely.
To correct this issue, I have done the following
- I've read this, this and this
- Double checked the file encoding, it's UTF-8
- Added the meta tag
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- Added the header inside php tag:
header("Content-type:text/html; charset: UTF-8");
- Added the internal encoding inside php tag
mb_internal_encoding('UTF-8');
- Corrected the line in php.ini file
default_charset = UTF-8
- Added the following in httpd.conf file:
AddDefaultCharset utf-8
- Everything is hard-coded, so I don't use database, it's not related to mysql encoding
I'm using WAMP, and machine is Windows 7 English. I'm completely exhausted, therefore, I really need help.
Thanks.