Hello All,
I'm a newer here. Just found this forum by googling. I'm not sure if this is the right place for my question or I should post it at PHP forum. Please forgive me if i'm wrong.
Here is my question:
I just get simple mboard php script that takes the meesage with Chinese characters (encoding gb2312) and writes it to a html file.
First, I tried: using gb2312 encoding in the html header file and the html page created by php script like this:
Quote:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>My Title in Chinese</title>
<meta content="text/html; charset=gb2312">
...
</head>
<body>
...
...(mixed Chinses and English characters)
...
</body>
</html>
|
The page is successfully created. However, when I looked at the page with IE, the IE automatically set the encoding to Western European (ISO) instead of using gb2312 even it is set in the head of the html file. So the Chinese characters are not correctly displayed. To see the page correctly I have to, every time, choose "gb2312" encoding from IE when i browe the page.
I also tried using uft-8 encoding, but same problem. Chinese charecters can be displayed when I manually set the proper encoding in IE. The problem is that IT could not detect and use the encoding in the html head and alway using Western European (ISO).
I don't know it the problem comes from the type of file php created or from the http server or anything wrong with the html file above.
I'm a newbie in html and php and totally lost. I wonder if antone can point me a direction. Thanks.
|