How to get my HTML file to read Cyrllic
Thread poster: Susan Welsh

Susan Welsh  Identity Verified
United States
Local time: 10:10
Member (2008)
Russian to English
+ ...
May 7, 2009

I am trying to set up a website for myself that shows sample translations side by side--in some approximation of the way ProZ does, although not so fancy. I have a lot of problems, but the main one is that Cyrillic comes out as gibberish. The file in the text editor (blah_blah.html) looks fine, but when I open it in a browser, the character encoding is ignored, or something.

I hope there is an easy solution...!

Susan


 

Piotr Bienkowski  Identity Verified
Poland
Local time: 16:10
Member (2005)
English to Polish
+ ...
Unicode May 7, 2009

Susan Welsh wrote:

I am trying to set up a website for myself that shows sample translations side by side--in some approximation of the way ProZ does, although not so fancy. I have a lot of problems, but the main one is that Cyrillic comes out as gibberish. The file in the text editor (blah_blah.html) looks fine, but when I open it in a browser, the character encoding is ignored, or something.

I hope there is an easy solution...!

Susan


If you want to display text in many languages and alphabets, Unicode is the answer. Regardless of the language, the text should be encoded in UTF-8 or UTF-16. What is the text editor you use?

HTH.

Regards

Piotr


 

Susan Welsh  Identity Verified
United States
Local time: 10:10
Member (2008)
Russian to English
+ ...
TOPIC STARTER
Text editor May 7, 2009

I am using the gedit text editor in Linux. I know to put .utf8 when creating an ordinary text file, but this is .html so I am not sure how to specify the encoding.

 

Frederic Lievre
Ireland
Local time: 15:10
English to French
+ ...
And also... May 7, 2009

Will have to be sure that the target browser can read the encoding...

 

Didier Briel  Identity Verified
France
Local time: 16:10
Member (2007)
English to French
+ ...
Use an encoding declaration May 7, 2009

Susan Welsh wrote:

I am using the gedit text editor in Linux. I know to put .utf8 when creating an ordinary text file, but this is .html so I am not sure how to specify the encoding.


You have to tell the browser the encoding of your document.

If you use UTF-8, that would be
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
somewhere in the "head" part - between <head> and </head>.

Of course, your document must also be saved as UTF-8, but this you already know.

Didier


[Edited at 2009-05-07 12:52 GMT]


 

Susan Welsh  Identity Verified
United States
Local time: 10:10
Member (2008)
Russian to English
+ ...
TOPIC STARTER
Target browser read the encoding? May 7, 2009

Frederic Lievre wrote:

Will have to be sure that the target browser can read the encoding...


I don't understand. It's Firefox, and it certainly can read Cyrillic documents. Maybe the problem is that I haven't specified an encoding so it's defaulting to something that can't be read. See reply to Didier, below.


 

Susan Welsh  Identity Verified
United States
Local time: 10:10
Member (2008)
Russian to English
+ ...
TOPIC STARTER
I already know? May 7, 2009

Didier Briel wrote:

Susan Welsh wrote:

I am using the gedit text editor in Linux. I know to put .utf8 when creating an ordinary text file, but this is .html so I am not sure how to specify the encoding.


You have to tell the browser the encoding of your document.

If you use UTF-8, that would be

somewhere in the "head" part - between and .

Of course, your document must also be saved as UTF-8, but this you already know.


The first part, I didn't know, so that I can easily do.
The second part, about saving as UTF-8 -- Well, I "already know" it for text files, but when a file has the extension .html, how do you save it as .utf8 also?

Susan


 

Didier Briel  Identity Verified
France
Local time: 16:10
Member (2007)
English to French
+ ...
No difference between text files and HTML May 7, 2009

Susan Welsh wrote:

Didier Briel wrote:

Susan Welsh wrote:

I am using the gedit text editor in Linux. I know to put .utf8 when creating an ordinary text file, but this is .html so I am not sure how to specify the encoding.


Of course, your document must also be saved as UTF-8, but this you already know.


The first part, I didn't know, so that I can easily do.
The second part, about saving as UTF-8 -- Well, I "already know" it for text files, but when a file has the extension .html, how do you save it as .utf8 also?


A HTML file is a text file. I think you're confusing extension (.utf8 or .html) and encoding. If, when you save your .utf8 files, they behave as UTF-8 files, this means the encoding is indeed UTF-8. Use the same procedure for your HTML files.

Didier


 

Piotr Bienkowski  Identity Verified
Poland
Local time: 16:10
Member (2005)
English to Polish
+ ...
Kwrite, Kate May 7, 2009

I don't know gedit, but I know for sure that both Kwrite and Kate can open and save utf 8 encoding without any problems.

You cound also try Quanta+, but I'm not sure if any of the three I mentioned runs under the Gnome environment.

HTH

Piotr


 

Vito Smolej
Germany
Local time: 16:10
Member (2004)
English to Slovenian
+ ...
Let's be practical... May 7, 2009

the header of the HTML file should contain charset statement as follows:

<head>
<meta content="text/html; charset=utf-8" http-equiv="content-type">
....


 

Susan Welsh  Identity Verified
United States
Local time: 10:10
Member (2008)
Russian to English
+ ...
TOPIC STARTER
Success May 7, 2009

What Didier and Vito said did the trick. Thanks to all for your help.

Susan


 


To report site rules violations or get help, contact a site moderator:


You can also contact site staff by submitting a support request »

How to get my HTML file to read Cyrllic

Advanced search






Protemos translation business management system
Create your account in minutes, and start working! 3-month trial for agencies, and free for freelancers!

The system lets you keep client/vendor database, with contacts and rates, manage projects and assign jobs to vendors, issue invoices, track payments, store and manage project files, generate business reports on turnover profit per client/manager etc.

More info »
Wordfast Pro
Translation Memory Software for Any Platform

Exclusive discount for ProZ.com users! Save over 13% when purchasing Wordfast Pro through ProZ.com. Wordfast is the world's #1 provider of platform-independent Translation Memory software. Consistently ranked the most user-friendly and highest value

More info »



Forums
  • All of ProZ.com
  • Term search
  • Jobs
  • Forums
  • Multiple search