Edit History Actions Discussion

Diff for "FAQ/Unicode"

Differences between revisions 2 and 13 (spanning 11 versions)
Revision 2 as of 2006-07-23 09:49:46
Size: 758
Comment:
Revision 13 as of 2009-03-06 12:45:43
Size: 989
Editor: host106-247
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
== Question ==
Does the shell provide Unicode support?
= Unicode =
Line 4: Line 3:
== Answer ==
Yes.
'''Question/Problem''': Are you having problems with character encodings?
Line 7: Line 5:
== Problem ==
Localized characters doesn't look good. (replaced by questionmarks etc)
'''Answer/Fix''': Try using Unicode/UTF-8.
Line 10: Line 7:
== Solution ==
Write this command at the shell prompt
== Commandline programs ==
Localized characters doesn't display correctly in irssi, nano etc (they are replaced with question marks, squares or something similar.)

'''Solution:'''

Write this command at the shell prompt (you don't need to do this if you already choose UTF-8 in the shell setup):
Line 14: Line 15:
echo 'export LC_ALL="en_US.UTF-8"' > ~/.profile}}} echo 'export LC_ALL="en_US.UTF-8"' >> ~/.profile}}}
Line 17: Line 18:
To use unicode in irssi, type this in the command prompt in irssi: For irssi, see [[FAQ/IrssiCharset]].

== Problem #2 - Webpages ==

Characters in webpages doesn't display correctly.

'''Solution:'''

Save the webpages in UTF-8 from your text-editor. Then create a new file named .htaccess in the same directory as your webpages (public_html) with the following content:
Line 20: Line 29:
/set term_charset UTF-8}}}
Use this command if you want to send text in another charset to other users that are still using ISO for example:
AddDefaultCharset UTF-8}}}
Line 23: Line 31:
{{{
/set recode_out_default_charset iso-8859-1}}}
Remember that you have to change the charset in your SSH-client aswell! Use the translation option in putty for example.
== See Also ==

 * [[FAQ/IrssiCharset|UTF in irssi]]
Line 27: Line 36:
["CategoryFAQ"]  [[CategoryFAQ]]

Unicode

Question/Problem: Are you having problems with character encodings?

Answer/Fix: Try using Unicode/UTF-8.

Commandline programs

Localized characters doesn't display correctly in irssi, nano etc (they are replaced with question marks, squares or something similar.)

Solution:

Write this command at the shell prompt (you don't need to do this if you already choose UTF-8 in the shell setup):

echo 'export LC_ALL="en_US.UTF-8"' >> ~/.profile

Next time you log in your shell will be in unicode.

For irssi, see FAQ/IrssiCharset.

Problem #2 - Webpages

Characters in webpages doesn't display correctly.

Solution:

Save the webpages in UTF-8 from your text-editor. Then create a new file named .htaccess in the same directory as your webpages (public_html) with the following content:

AddDefaultCharset UTF-8

See Also