This patch should help write w3c conformant XHTML web pages while
using PHPlib. It is released against phplib 7.4rc1
For a
definition of the problem see bug #501788.
WARNING: the patch
will print urls containing '&' instead of '&' characters as
argument separators; if your website code does a lot of URL mangling
magic it is likely to fall apart...
maybe a better option would
be to have a different set of procedures that output XMTHL valid
URLs, instead of patching the current one... who
knows?
Anyway, here it is the (modified) last lines of function
url() in session.inc:
// Encode naughty characters in the
URL
$url = str_replace(array("<", ">", " ", "\&quot;", "'", "&",
"&amp;amp;"), // G. Giunta 2002/01/10
array("%3C", "%3E", "+",
"%22", "%27", "&amp;", "&amp;"), $url); // G. Giunta 2002/01/10