From a6544b37d95600bbcac3712d2597a084d68bcb1b Mon Sep 17 00:00:00 2001 From: Daniel Kraus Date: Wed, 20 Feb 2013 21:47:23 +0100 Subject: [PATCH] Add preliminary support for __NOAUTOLINKS__ magic word. --- LinkTitles.body.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/LinkTitles.body.php b/LinkTitles.body.php index ecba0d4..7a11143 100755 --- a/LinkTitles.body.php +++ b/LinkTitles.body.php @@ -73,6 +73,12 @@ /// This function performs the actual parsing of the content. static function parseContent( &$article, &$text ) { + // If the page contains the magic word '__NOAUTOLINKS__', do not parse + // the content. + if ( strpos( $text, '__NOAUTOLINKS__' ) !== false ) { + return true; + } + // Configuration variables need to be defined here as globals. global $wgLinkTitlesPreferShortTitles; global $wgLinkTitlesMinimumTitleLength;