Re: DTD 4.01 for ignoring & in CGI URL

On Mon, 23 Jul 2001, Terje Bless wrote:

> Nestor: I think I can throw together a patch to "check" for you that will
> ignore messages specifically for amperstands in URIs.

OTTOMH (meaning don't use without testing ;-)

s/(<a.+?>)/escape_amp($1)/geis ;

with

sub escape_amp { s/&/&amp;/g ; return $_ ; }


The old WebTechs validator just put the whole document through
s/&/&amp;/g ;

which of course has the desired effect, but also the side-effect of
failing to catch other non-entities.

-- 
Nick Kew

Site Valet - the essential service for anyone with a website.
<URL:http://valet.webthing.com/>

Received on Monday, 23 July 2001 16:46:27 UTC