Forum Moderators: open

Message Too Old, No Replies

Euro Symbol and HTML Validation.

It doesn't validate

         

abbeyvet

5:28 pm on Sep 16, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Everything validates to HTML 4.01 on my template page except the Euro symbol.

I am lost in a morass of stuff about iso chatacters but cannot find what I need to replace the symbol with.

This is my doctype, in case that is relevant.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

Sinner_G

5:32 pm on Sep 16, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try replacing the € by the &euro; encoding.

g1smd

12:43 am on Sep 17, 2003 (gmt 0)

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



Don't use symbols for currency at all.

The symbol: $ has dozens of meanings for example.

Use the codes in ISO 4217, an international standard agreed by over 200 countries, instead.

ISO 3166 gives country codes, and ISO 639 is used for codes for languages too.

abbeyvet

8:25 pm on Sep 18, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thank you, I have used the &euro; and it validates now.

I am aware of ISO codes but have thus far failed to locate a resource that makes how to use them in practical terms even vaguely clear. If you know of such a resource I would appreciate the pointer.

g1smd

10:05 pm on Sep 18, 2003 (gmt 0)

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



See these:

xe.net/currency

directory.google.com/Top/Science/Reference/Standards/Individual_Standards/ISO_4217/

MonkeeSage

4:17 am on Sep 20, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



These are the standard XHTML entities...

view-source:http://www.w3.org/TR/xhtml1/DTD/xhtml-lat1.ent
view-source:http://www.w3.org/TR/xhtml1/DTD/xhtml-special.ent
view-source:http://www.w3.org/TR/xhtml1/DTD/xhtml-symbol.ent

Each entity has a descriptive comment next to it indicating what the entity represents. For example, euro is the last entity listed in the second document in link above (xhtml-special.ent). It looks like this:

<!ENTITY euro "&#8364;"> <!-- euro sign, U+20AC NEW -->

You can use the standard entity &euro; or the hex entity it evaluates out to &#8364;. You can also use the full unicode scan code given in the comment in your JavaScripts by using the unicode escape (\u), like

document.write("\u20AC");

Jordan

abbeyvet

8:17 am on Sep 20, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thank you. Sorted now.