RE: Whitespace In Attribute Values

> XHTML attributes aren't supposed to have any whitespace in them.

I assume you read point 4.7 of <http://www.w3.org/TR/2000/REC-xhtml1-20000126/#diffs>
"In attribute values, user agents will strip leading and trailing
whitespace from attribute values and map sequences of one or more
whitespace characters (including line breaks) to a single inter-word
space (an ASCII space character for western scripts)."

and subsequently followed on to read <http://www.w3.org/TR/REC-xml#AVNormalize>

I have to admit, I had to read that last one a few times as well, but
if I'm not mistaken the crucial point is this:
"the XML processor must normalize the attribute value"

In other words: you, as web author/developer, can use whitespace as
usual. It's the XML processor that needs to then (internally) convert
all whitespace characters until they meet those requirements. You can
write your titles as normal, i.e. title="A new link."

At least, that's what I understood. Somebody please slap me in the
face with a big salmon if I'm talking nonsense.

Patrick
________________________________
Patrick H. Lauke
Webmaster / University of Salford
http://www.salford.ac.uk

Received on Tuesday, 29 July 2003 10:51:49 UTC