diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2013-01-18 16:46:04 +0100 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2013-01-18 16:46:04 +0100 |
commit | 63601400e476c6cf43d985f3e7b9864681695ed4 (patch) | |
tree | f7846203a952e38aaf66989d0a4702779f549962 /includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php | |
parent | 8ff01378c9e0207f9169b81966a51def645b6a51 (diff) |
Update to MediaWiki 1.20.2
this update includes:
* adjusted Arch Linux skin
* updated FluxBBAuthPlugin
* patch for https://bugzilla.wikimedia.org/show_bug.cgi?id=44024
Diffstat (limited to 'includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php')
-rw-r--r-- | includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php b/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php index 02693d3e..0e95d964 100644 --- a/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php +++ b/includes/resourceloader/ResourceLoaderUserCSSPrefsModule.php @@ -1,5 +1,7 @@ <?php /** + * Resource loader module for user preference customizations. + * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or @@ -69,13 +71,6 @@ class ResourceLoaderUserCSSPrefsModule extends ResourceLoaderModule { $rules[] = 'a:lang(ar), a:lang(ckb), a:lang(fa),a:lang(kk-arab), ' . 'a:lang(mzn), a:lang(ps), a:lang(ur) { text-decoration: none; }'; } - if ( $options['highlightbroken'] ) { - $rules[] = "a.new, #quickbar a.new { color: #ba0000; }\n"; - } else { - $rules[] = "a.new, #quickbar a.new, a.stub, #quickbar a.stub { color: inherit; }"; - $rules[] = "a.new:after, #quickbar a.new:after { content: '?'; color: #ba0000; }"; - $rules[] = "a.stub:after, #quickbar a.stub:after { content: '!'; color: #772233; }"; - } if ( $options['justify'] ) { $rules[] = "#article, #bodyContent, #mw_content { text-align: justify; }\n"; } @@ -86,7 +81,10 @@ class ResourceLoaderUserCSSPrefsModule extends ResourceLoaderModule { $rules[] = ".editsection { display: none; }\n"; } if ( $options['editfont'] !== 'default' ) { - $rules[] = "textarea { font-family: {$options['editfont']}; }\n"; + // Double-check that $options['editfont'] consists of safe characters only + if ( preg_match( '/^[a-zA-Z0-9_, -]+$/', $options['editfont'] ) ) { + $rules[] = "textarea { font-family: {$options['editfont']}; }\n"; + } } $style = implode( "\n", $rules ); if ( $this->getFlip( $context ) ) { |