lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: lynx-dev Conversion of special character codes within anchor t


From: Greg Marr
Subject: Re: lynx-dev Conversion of special character codes within anchor tags
Date: Thu, 24 Sep 1998 15:56:04 -0400

At 11:14 PM 9/24/98 +0400, Leonid Pauzner wrote:
>NO/yes. According SGML/HTML entities should begins with '&' and ends with ';'

No, entities end with the first character which isn't valid in an entity
name. 
The ; at the end of the entity terminates the entity, but is taken as part of
the entity.  Any other character ends the entity but is not taken as part of
the entity, and so is still in the stream to be processed.  The ; is only
required when the character following the end of the entity would otherwise be
interpreted as part of the entity.  In practice, one should always use the
; at
the end, because sometimes it is necessary, and it can never hurt to have it
there.  The same goes for quoting attribute values.

<http://www.w3.org/TR/REC-html40/charset.html#entities>http://www.w3.org/TR
/REC-html40/charset.html#entities, HTML section 5.3

Note. In SGML, it is possible to eliminate the final ";" after a character
reference in some cases (e.g., at a line break or immediately before a
tag). In
other circumstances it may not be eliminated (e.g., in the middle of a word).
We strongly suggest using the ";" in all cases to avoid problems with user
agents that require this character to be present. 

Bruno Prior wrote:
>It has been put to me in a previous discussion that, because HTML standards
>do not specify that URLs in anchor tags should be treated differently to
>other text on the page, this means that they should be treated the same.

HTML 4.0 DOES specify that they should be treated the same.

<http://www.w3.org/TR/REC-html40/charset.html#entities>http://www.w3.org/TR
/REC-html40/charset.html#entities, HTML section 5.3.2
Authors should use "&amp;" (ASCII decimal 38) instead of "&" to avoid
confusion
with the beginning of a character reference (entity reference open delimiter).
Authors should also use "&amp;" in attribute values since character references
are allowed within CDATA attribute values. 

I think this section clearly states that Lynx's current behavior is correct.

--
Greg Marr
address@hidden
"We thought you were dead." 
"I was, but I'm better now." - Sheridan, "The Summoning"

reply via email to

[Prev in Thread] Current Thread [Next in Thread]