[thelist] url encoding links to external sites

Simon Willison cs1spw at bath.ac.uk
Sun Nov 2 13:49:33 CST 2003

fstorr wrote:

> Hi all
> Probably simple, but my brain is near mush.  I need my page to
> validate to XHTML1.0 but have this link:
> http://www.nationaltrust.org.uk/scripts/nthandbook.dll?ACTION=PROPERTY&PROPERTYID=5
> That, because it contains reserved characters, is causing my page not
> to validate.  I've tried encoding the ? with %3f and the = with %3d
> etc, but the URL then won't play with the national trust's server.
> Is there a way out of this?

You just need to replace the & with & - the question mark isn't the 


Simon Willison
Web development weblog: http://simon.incutio.com/

More information about the thelist mailing list