On Tue, 29 Nov 2005 00:09:04 +1100, Netocrat wrote:
I noticed while validating the HTML output of an
extension that some
urls are being generated with a plain & instead of encoded as & and
the W3C validator complains about this as an error. This patch fixes
the line of code that was the source of the uncoded ampersand (and
another line I noticed) if anyone with CVS access chooses to apply it.
Looks like the attachment's been stripped on gmane. Here it is inline.
Index: Title.php
===================================================================
RCS file: /cvsroot/wikipedia/phase3/includes/Title.php,v
retrieving revision 1.243
diff -u -r1.243 Title.php
--- Title.php 13 Nov 2005 04:09:06 -0000 1.243
+++ Title.php 28 Nov 2005 11:30:53 -0000
@@ -678,7 +678,7 @@
if( false === strpos( $url, '?' ) ) {
$url .= '?';
} else {
- $url .= '&';
+ $url .= '&';
}
$url .= $query;
}
@@ -725,7 +725,7 @@
if ( $query == '-' ) {
$query = '';
}
- $url = "{$wgScript}?title={$dbkey}&{$query}";
+ $url = "{$wgScript}?title={$dbkey}&{$query}";
}
}
--
http://members.dodo.com.au/~netocrat