Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have been seeing these strange symbols for a while now, and am curious as to what they are, and why they appear. Sometimes, they appear so frequently in one page, the writing is indecipherable. The symbols appear as they do below in Firefox, but they appear as little squares in Internet Explorer.

Here's an example:

enter image description here

  1. What are they?
  2. How do I get rid of them?
share|improve this question

migrated from Oct 25 '09 at 7:42

This question came from our site for professional and enthusiast programmers.

In general Firefox renders all Unicode characters that it can't find a glyph for in your fonts as a box containing the character code. If you go to eg. a Chinese web site and you don't have Chinese fonts installed, you'll get nothing but little boxes.

However that particular character in the screenshot is � U+FFFD REPLACEMENT CHARACTER. (I get a diamond shape with a question mark; you might also get a square box or just a question mark.)

Unless someone has deliberately typed that character, which is unlikely (except for me just doing it above), U+FFFD means someone has screwed up their encodings at some point along the line, and either:

  • tried to encode a character into an encoding that doesn't support it, for example if someone tried to send a Chinese character in a Latin-1 encoding, or

  • served an encoded byte sequence as UTF-8 when actually it's something else.

In the particular screenshot it is clearly a problem where “smart quotes” have been submitted as single Windows code page 1252 bytes. Then the data has probably been misattributed as UTF-8.

Where the misattribution is due to your browser guessing the charset wrong (for stupid pages that don't label their charsets), you can fix it by going to View->Encoding and guessing the right one. Where the misattribution is due to the web site's own processing of strings, there's not much you can do about it. Unfortunately many web sites get charsets wrong, particularly those written in Unicode-ignorant languages like PHP, classic-ASP, Ruby and JSP (despite Java's native strings, JSP/Servlet is pretty broken wrt encodings).

share|improve this answer

They're unicode PLACEHOLDERS; the number represents the unicode codepoint for the glyph that's missing in the font(s) available. Use a font that covers more of the unicode characters needed, and these boxes will be replaced by nice international characters.

Note that this can also be caused by having the browser (or other app) assume the wrong document encoding. For instance, if your character encoding settings specify that a document should be interpreted as cyrillic (russian) encoding, and your document is actually encoded as chinese, then then you'll get wrong glyphs where the character maps happen to overlap, and placeholder glyphs (the boxes with numbers) where the character maps don't overlap.

share|improve this answer

They're unicode symbols; I asked this question w/r/t printing on superuser.

share|improve this answer
Hey thanks.. I tried changing the settings as described in your post in superuser, but the symbols still appear. But atleast I know what they are now, so cheers:) – Lea Oct 25 '09 at 3:15

The characters that the symbol represents are smart quotes ( and ), incorreclty input by an all-too-eager copy and paste finger. Or rather they're what programs like Microsoft Word uses to represent smart quotes. Either the both quotes should be ", or the first should be “ and the second ”.

share|improve this answer

You must log in to answer this question.