Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Wondering if someone could help me out with a weird little problem i'm having.
Middots (· are not displaying correctly, neither are some other special characters. I get a ? in a black diamaond.This happens when looking at file names on the server through SSH and when browsing the page using a web browser.
System setup if it helps:
4 core cpu
8gb ram
250 gb hdd
Centos 6.2 basic install
Apache
PHP
ColdFusion 8
Stuff I've tried:
checked this line is in the apache conf file -
IndexOptions FancyIndexing VersionSort HTMLTable NameWidth=* Charset=UTF-8
Added MS true type fonts to the O/S
Checked ColdFusion to make sure the fonts are loaded, they are, and this is happening on flat html pages as well as file names on the O/S so don't think its a web issue but a system wide problem.
I've searched Google and the forums here relentlessly but am having little luck. I have found some posts that are close to my problem so have followed their suggestions but with no luck so far.
I have found in /etc/sysconfig/i18n I have this:
LANG="en_US.UTF-8"
SYSFONT="latarcyrheb-sun16"
I am not sure about the sysfont being correct but am unsure what it should be changed to.
Also i have found this in a forum post "ensure this line is present on each page" <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> I have done this and this has not helped either. I thought it could be because in the apache httpd.conf file i had entered charset=utf-8 so i commented this out, restarted apache and still no joy.
This is a live production server so anything that may kill it please let me know first!
About web browser (and server) - displaying entities for example · is dependent only on the client side (web browser), obviously server sends just these characters: ampersand,m,i,d,d,o,t,; not a one character. So this is problem with your browser or system fonts where this browser is installed - not a web server. I assume that they are written correctly, as entity, not incorrectly as coded character in UTF8 or other charset. And, if web browser display some questiuon marks in place of middot character, then it means that font currently used has not defined that character. In browser you can usualy change font for display.
Hi,
Its not a problem with the browser, because Chrome, FF, and IE can't possibly all fail to display the same thing, my colleagues also cannot see the special characters and they are using win 7 where as i am on XP so i know its not an issue with my computer. Also the customer cannot see these special characters on his computer, which is a mac and using safari as far as i am aware. We have also tested using an Ipad.
Also, i'm 99% sure that the server doesn't send m,i,d,d,o,t,; to the browser. It uses a character map to map the special character - for example a middot under utf-8 is sent as 'c2 b7' then the browser would decode this based on the meta information of the webpage using the character map on the local machine. I know its not a web browser issue because we see the same thing on the linux filesystem - the filenames have ?'s in them rather than long dashes (-)
I would be interested in getting some more information about
"I assume that they are written correctly, as entity, not incorrectly as coded character in UTF8 or other charset"
Could you give me an example?
Also, i'm 99% sure that the server doesn't send m,i,d,d,o,t,; to the browser. It uses a character map to map the special character
Then make sure that the served files are saved in UTF8 and Content-Type sended to browser is also UTF8, do not change it to "iso-8859-1". There are two places to check, the server headers (Tamper Data extension to Firefox can be helpful or just use sniffer) and html headers (those between <HEAD>).
About characters on filesystem is the same - font and console settings. For example on Kubuntu in virtual console for displaing text in UTF8, I need to use "setfont" with proper font file like "/usr/share/consolefonts/Uni3-Terminus16.psf.gz". But I don't known where are settings for your operating system. You did not mentioned if this happen under terminal emulator on X server or in "text mode" (after switching CTRL+ALT+F1)?
The character "? in a black diamond" is Unicode U+FFFD: "used to replace an incoming character whose value is unknown or unrepresentable in Unicode". Non-unicode encodings will fall in the 0-FF range (unless the old Sino-Japanese ones) and generate the wrong character (or perhaps a box for a control code). It looks like you're getting a number greater than FF that is not a valid encoding format in UTF-8. Could it be that you're getting UTF-16 or something weird like CESU-8? Can you get the offending symbol into a hex editor and find what it is?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.