homepage Welcome to WebmasterWorld Guest from 54.227.146.68
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / WebmasterWorld / Webmaster General
Forum Library, Charter, Moderators: phranque & physics

Webmaster General Forum

    
Just uploaded. why am I seeing chinese symbols?
Rightz




msg:348233
 9:26 pm on May 16, 2006 (gmt 0)

I've just uploaded my to a host I'm trying a 14 day trial with.

However when I go to that page all I can see is Chinese Symbols... and it seems to be showing the source code.

Check out my site to see what I mean...

<snip>

I'm not advertising - just thought it might be easier if you see what I'm talking about. I've only put the words 'coming soon' on this page to test.

What have I done wrong?!

[edited by: trillianjedi at 10:25 am (utc) on May 17, 2006]
[edit reason] TOS [/edit]

 

Rightz




msg:348234
 9:54 pm on May 16, 2006 (gmt 0)

I should add this happens on each page I've tried - no matter the content. I know the html is correct.

Is it something to do with my host? My ftp software (although never seen this before)? My domain registrant?

None of them are chinese!

kaled




msg:348235
 11:44 pm on May 16, 2006 (gmt 0)

First, TOS prohibit personal urls, however, the source code of the page home.html looked like this (abbreviated)...

<html><head></head[red]er[/red]>?...?</body></html>

The site url returns a directory list. To avoid this, you need a file with a name such as index.html, but other names are acceptable depending on server configuration.

Kaled.

UserFriendly




msg:348236
 12:19 am on May 17, 2006 (gmt 0)

Your server is returning this in its response header:

Content-Type:text/html (BOM UTF-16, litte-endian)

You might want to be using UTF-8 as a character encoding, but I've no idea what BOM UTF-16 is.

Seeing as your server is based in the United States (according to IP address geolocation), I've no idea why it would be sending such an odd Content-Type header.

Check what character encoding you're using in your HTML editor. If it doesn't look like that's to blame, then ask your server admin why the web server is specifying such an odd encoding.

Rightz




msg:348237
 10:43 am on May 17, 2006 (gmt 0)

I've contacted my host but they are pretty useless. Is it my host or registrant that needs to deal with this?

The only editor I use is notepad.

Would it help if I added this UTF-8 code in somewhere - sorry quite ignorant on this!

larryhatch




msg:348238
 11:04 am on May 17, 2006 (gmt 0)

Here's the line I use.

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

Put that just after the <head> statement and before the <title>

Note the semicolon you are missing. Just cut and paste from this posting.

I don't know where you got that other content type, I would remove it as a test. -Larry

Rightz




msg:348239
 11:34 am on May 17, 2006 (gmt 0)

Thanks for all the advice

I tried putting in that code but after asking my host why it isn't showing up they replaced it with:

<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">

His reponse was:

<quote>
The problem is in the headers of your page, you are encoding the page as UTF-8, most of the
UTF-8 characters are Chinese.

I have changed the encoding of the page to iso-8859-1 it now functions correctly.
</quote>

Which works - however I've tried it on other pages and they are still showing Chinese symbols - is this simply a problem with my host. I'm on a 14 day trial and am not impressed so far. Would you consider trying someone else?

davidpbrown




msg:348240
 11:48 am on May 17, 2006 (gmt 0)

BOM UTF-16 suggests you might have a Byte Order Mark on the front of your file.

You need to save the files UTF-8 without BOM and to do this you need an editor that gives that option.

Several editors are listed on Alan Wood’s Unicode Resources - Multilingual Editors [alanwood.net]. I'd recommend EmEditor having used it..

Some editors save as "UTF"=UTF-16 and not UTF-8. Wordpad on Windows 98 is one that does that.

I expect then data within the file is read as 16byte characters many of which are Chinese.

Alternatively, if you're not using characters outside iso-8859-1 you could simply save all your files as ASCII or iso-8859-1.

HTH

Rightz




msg:348241
 12:06 pm on May 17, 2006 (gmt 0)

I use notepad. I've never had this problem before - why now?

davidpbrown




msg:348242
 12:25 pm on May 17, 2006 (gmt 0)

Check the encoding you are saving as. Notepad offers several flavours ANSI, Unicode, Unicode big endian and UTF-8. Maybe the default changed from ANSI to Unicode big endian?

collymellon




msg:348243
 12:35 pm on May 17, 2006 (gmt 0)

It is not a problem with your host, it is a problem with your source code.

I don't see what the fuss about? change every page to reflect the correct encoding and thats it done.

If you ask me the host has been kind enough to locate the problem and tell you exactly where you have gone wrong.

Rightz




msg:348244
 2:26 pm on May 17, 2006 (gmt 0)

Thanks for all your help. Got it now - was saving the file in notepad incorrectly.

Cheers

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / WebmasterWorld / Webmaster General
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved