[thelist] validation

Ben Henick persist1 at io.com
Fri Dec 14 19:55:06 CST 2001


On Fri, 14 Dec 2001, Diego Lafuente wrote:

> you see that number? ok thats a hexa char set
>
> you need to convert the & to %equalnumber
>
> i forgot the formula to convert from iso to hexa

Just convert the given decimal values to hex, is all.  calc.exe in Windows
will do this in Sci mode.  (Does the calculator utility on the Mac do
this, also?)

> if someone can provide us with a table or a formula so we can use this

A search for 'ascii character table' will turn up several.

When seeking to validate, however, you're best off using a named entity
whenever possible.  These are published as an appendix to the HTML 4.01
Recommendation.

The & solution will be the best to use, as more recent browsers parse
this and convert it before sending the appropriate request.

Having tried the escaped ASCII value for '&' (which is 0x26 or %26 IIRC) I
can tell you that many server setups will not un-escape these references
before the called script gets run.

As someone who's been spending most of his day converting his Weblog
archive (246 posts, approaching 100K words) to valid XHTML 1.0, I've
learned more about this than I care to deal with right now.  Urgh.


-- 
Ben Henick
Web Author At-Large              Managing Editor
http://www.io.com/persist1/      http://www.digital-web.com/
persist1 at io.com                  bmh at digital-web.com
--
"Are you pondering what I'm pondering, Pinky?"
"I think so, Brain, but... (snort) no, no, it's too stupid."
"We will disguise ourselves as a cow."
"Oh!" (giggles) "That was it exactly!"






More information about the thelist mailing list