Follow up r93633. Allow only classic spaces.

This commit is contained in:
Platonides 2011-08-02 16:23:46 +00:00
parent 801a05afc2
commit 76e7c63bff

View file

@ -4336,9 +4336,9 @@ class Parser {
$tc = "[$wgLegalTitleChars]";
$nc = '[ _0-9A-Za-z\x80-\xff-]'; # Namespaces can use non-ascii!
$p1 = "/\[\[(:?$nc+:|:|)($tc+?)(\s?\\($tc+\\))\\|]]/"; # [[ns:page (context)|]]
$p4 = "/\[\[(:?$nc+:|:|)($tc+?)(\s?$tc+)\\|]]/"; # [[ns:pagecontext|]]
$p3 = "/\[\[(:?$nc+:|:|)($tc+?)(\s?\\($tc+\\)|)(, $tc+|)\\|]]/"; # [[ns:page (context), context|]]
$p1 = "/\[\[(:?$nc+:|:|)($tc+?)( ?\\($tc+\\))\\|]]/"; # [[ns:page (context)|]]
$p4 = "/\[\[(:?$nc+:|:|)($tc+?)( ?$tc+)\\|]]/"; # [[ns:pagecontext|]]
$p3 = "/\[\[(:?$nc+:|:|)($tc+?)( ?\\($tc+\\)|)(, $tc+|)\\|]]/"; # [[ns:page (context), context|]]
$p2 = "/\[\[\\|($tc+)]]/"; # [[|page]]
# try $p1 first, to turn "[[A, B (C)|]]" into "[[A, B (C)|A, B]]"