Page MenuHomePhabricator

multiline <noinclude> / <includeonly> fails
Closed, ResolvedPublic

Description

Credits for finding this go to an anonymous user on
http://www.mediawiki.org/wiki/Extension_talk:MultiBoilerplate#noinclude_included

MultiBoilerplate fails to match <noinclude> and <includeonly> if the closing tag is not in the same wikitext line.

I can't provide a clean patch because I'm already using a patched version of MultiBoilerplate (see my other bugreports), therefore I'm including a pseudo-patch ;-)

  • MultiBoilerplate.php (Revision 71216)

+++ MultiBoilerplate.php (Arbeitskopie)
@@ -140,2 +140,2 @@

  • $content = preg_replace( '#<noinclude>(.*?)</noinclude>#', '', $content );
  • $content = preg_replace( '#<includeonly>(.*?)</includeonly>#', '$1', $content );

+ $content = preg_replace( '#<noinclude>(.*?)</noinclude>#ims', '', $content );
+ $content = preg_replace( '#<includeonly>(.*?)</includeonly>#ims', '$1', $content );

The difference is the additional 'ims' in both search patterns.


Version: unspecified
Severity: normal

Details

Reference
bz32710
TitleReferenceAuthorSource BranchDest Branch
Update function-schemata sub-module to HEAD (04c5c89)repos/abstract-wiki/wikifunctions/wikilambda-cli!32jforrestersync-function-schematamain
Update function-schemata sub-module to HEAD (04c5c89)repos/abstract-wiki/wikifunctions/function-evaluator!171jforrestersync-function-schematamain
Update function-schemata sub-module to HEAD (04c5c89)repos/abstract-wiki/wikifunctions/function-orchestrator!137jforrestersync-function-schematamain
Update function-schemata sub-module to HEAD (786c586)repos/abstract-wiki/wikifunctions/wikilambda-cli!30jforrestersync-function-schematamain
Update function-schemata sub-module to HEAD (786c586)repos/abstract-wiki/wikifunctions/function-evaluator!163jforrestersync-function-schematamain
[UNBREAKING CHANGE] Update function-schemata sub-module to HEAD (786c586)repos/abstract-wiki/wikifunctions/function-orchestrator!134jforrestersync-function-schematamain
Implement a stable stringify algorithm (keys are always sorted).repos/abstract-wiki/wikifunctions/function-schemata!87apineapine-implement-stable-stringifymain
Move ZObjectKeyFactory to utils so it can be used by downstream consumers.repos/abstract-wiki/wikifunctions/function-schemata!86apineapine-move-key-factorymain
Customize query in GitLab