* @param $cache Boolean
*/
public function outputWikiText( $text, $cache = true ) {
- global $wgParser, $wgUser, $wgOut, $wgEnableParserCache, $wgUseFileCache;
+ global $wgParser, $wgOut, $wgEnableParserCache, $wgUseFileCache;
$popts = $wgOut->parserOptions();
$popts->setTidy(true);
* the newly-edited page.
*/
function edit() {
- global $wgOut, $wgUser, $wgRequest;
+ global $wgOut, $wgRequest;
// Allow extensions to modify/prevent this form or submission
if ( !wfRunHooks( 'AlternateEdit', array( &$this ) ) ) {
return;
* Show a notice that the file is from a shared repository
*/
protected function printSharedImageText() {
- global $wgOut, $wgUser;
+ global $wgOut;
$this->loadFile();
* @param $prefix String: optional prefix. As trail, only before instead of after.
*/
function makeLinkObj( $nt, $text= '', $query = '', $trail = '', $prefix = '' ) {
- global $wgUser;
wfProfileIn( __METHOD__ );
$query = wfCgiToArray( $query );
* LogEventsList::NO_ACTION_LINK Don't show restore/unblock/block links
*/
function __construct( &$reader, $flags = 0 ) {
- global $wgUser;
wfDeprecated(__METHOD__);
$this->reader =& $reader;
$this->reader->pager->mLogEventsList->flags = $flags;
* arrays (errors) as values, or an error array with numeric indices if no pages were moved
*/
public function moveSubpages( $nt, $auth = true, $reason = '', $createRedirect = true ) {
- global $wgUser, $wgMaximumMovedPages;
+ global $wgMaximumMovedPages;
// Check permissions
if( !$this->userCan( 'move-subpages' ) )
return array( 'cant-move-subpages' );
* Log this user out.
*/
function logout() {
- global $wgUser;
if( wfRunHooks( 'UserLogout', array(&$this) ) ) {
$this->doLogout();
}
* Patrols the article or provides the reason the patrol failed.
*/
public function execute() {
- global $wgUser, $wgUseRCPatrol, $wgUseNPPatrol;
+ global $wgUser;
$params = $this->extractRequestParams();
if(!isset($params['token']))
* Run the transaction
*/
function execute() {
- global $wgUser, $wgUseSquid;
+ global $wgUseSquid;
wfProfileIn( __METHOD__ );
$this->file->lock();
* So we save the batch and let the caller call cleanup()
*/
function execute() {
- global $wgUser, $wgLang;
+ global $wgLang;
if ( !$this->all && !$this->ids ) {
// Do nothing
return $this->file->repo->newGood();
* @todo This would probably look a lot nicer in a table.
*/
function formatRow( $row ) {
- global $wgLang, $wgUser, $wgContLang;
+ global $wgLang, $wgContLang;
wfProfileIn( __METHOD__ );
$sk = $this->getSkin();
function formatRow( $row ) {
wfProfileIn( __METHOD__ );
- global $wgLang, $wgUser;
+ global $wgLang;
$sk = $this->getSkin();
}
function execute() {
- global $wgOut, $wgUser;
+ global $wgOut;
$wgOut->setPagetitle( wfMsgHtml( "mergehistory" ) );
}
function formatRevisionRow( $row ) {
- global $wgUser, $wgLang;
+ global $wgLang;
$rev = new Revision( $row );
}
function merge() {
- global $wgOut, $wgUser;
+ global $wgOut;
# Get the titles directly from the IDs, in case the target page params
# were spoofed. The queries are done based on the IDs, so it's best to
# keep it consistent...
* @return string
*/
public function formatRow( $result ) {
- global $wgLang, $wgContLang, $wgUser;
+ global $wgLang, $wgContLang;
$classes = array();
}
function wfSpecialRemoveRestrictionsProcess( $r ) {
- global $wgUser, $wgRequest;
+ global $wgRequest;
$reason = $wgRequest->getVal( 'reason' );
$result = $r->delete();
$log = new LogPage( 'restrict' );
* @return string HTML
*/
function showDiff( $previousRev, $currentRev ) {
- global $wgOut, $wgUser;
+ global $wgOut;
$diffEngine = new DifferenceEngine();
$diffEngine->showDiffStyle();
* @access private
*/
function processUpload(){
- global $wgUser, $wgOut, $wgFileExtensions, $wgLang;
+ global $wgOut, $wgFileExtensions, $wgLang;
$details = null;
$value = null;
$value = $this->internalProcessUpload( $details );
* @private
*/
function onCookieRedirectCheck( $type ) {
- global $wgUser;
-
if ( !$this->hasSessionCookie() ) {
if ( $type == 'new' ) {
return $this->mainLoginForm( wfMsgExt( 'nocookiesnew', array( 'parseinline' ) ) );
### "<day> d' <monthname>" for months starting with a vowel
###
function date( $ts, $adj = false, $format = true, $tc = false ) {
- global $wgUser;
-
if ( $adj ) { $ts = $this->userAdjust( $ts, $tc ); }
$datePreference = $this->dateFormat( $format );