Forum Moderators: phranque

Message Too Old, No Replies

Can't get the ♦ character to show up

♠ ♥ ♣ all work fine

         

MichaelBluejay

9:10 am on May 9, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



The ♦ character shows up fine in Safari, but in Windows it just shows as a box. To fix it I tried all of the following, one at a time, none of which helped:

* Added "AddType 'text/html; charset=ISO-8859-1' html" to the .htaccess file
* Added "<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">" as the first line of the page.
* Added "<meta http-equiv="content-type" content="text/html; charset=UTF-8">" to the <head> section on the page
* Substituted the numeric equivalent, &#9830;

Any ideas before I resort to using an image file instead?

choster

1:35 pm on May 9, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Which is it-- ISO-8859-1 or UTF-8? The encoding in the .htaccess file should match the encoding of the document itself.

Also, the character glyph must appear in the font that you are using. Most fonts contain a limited number, and Mac fonts may have different glyphs from Windows fonts.

Lastly, Internet Explorer recognizes far fewer Unicode entities than more modern browsers, so even if the character appears in Firefox or Opera on the same machine, it may not in IE.

MichaelBluejay

5:50 am on May 10, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Font? What's a font? :)

Actually, that was it -- the character shows up in Arial but not in Verdana.

I just went ahead and made an image file and use that. With a mod_Rewrite redirect it's not even much more code -- <img src/diams>. Plus, with the image, I can make the character RED, like it's supposed to be. I did the same for hearts.