Go to the documentation of this file.
33 $subtype = $this->entry->getSubtype();
34 if ( $subtype ===
'move_prot' ) {
42 $key = parent::getMessageKey();
53 $params = parent::getMessageParameters();
55 $subtype = $this->entry->getSubtype();
56 if ( $subtype ===
'protect' || $subtype ===
'modify' ) {
57 $rawParams = $this->entry->getParameters();
58 if ( isset( $rawParams[
'details'] ) ) {
60 } elseif ( isset(
$params[3] ) ) {
62 $params[3] = $this->context->getLanguage()->getDirMark() .
$params[3];
72 } elseif ( $subtype ===
'move_prot' ) {
74 $params[3] = Message::rawParam( $oldname );
81 $linkRenderer = MediaWikiServices::getInstance()->getLinkRenderer();
82 $subtype = $this->entry->getSubtype();
84 || $subtype ===
'move_prot'
90 $title = $this->entry->getTarget();
96 'action' =>
'history',
97 'offset' => $this->entry->getTimestamp(),
103 if ( $this->context->getUser()->isAllowed(
'protect' ) ) {
106 $this->
msg(
'protect_change' )->
text(),
108 [
'action' =>
'protect' ]
112 return $this->
msg(
'parentheses' )->rawParams(
113 $this->context->getLanguage()->pipeList( $links ) )->escaped();
122 if ( $subtype ===
'protect' || $subtype ===
'modify' ) {
126 'details' =>
':array:details',
128 } elseif ( $subtype ===
'move_prot' ) {
131 '4::oldtitle' =>
'4:title:oldtitle',
134 foreach ( $map
as $index => $key ) {
135 if ( isset(
$params[$index] ) ) {
142 if ( isset(
$params[
'5:bool:cascade'] ) && is_string(
$params[
'5:bool:cascade'] ) ) {
143 $params[
'5:bool:cascade'] =
$params[
'5:bool:cascade'] ===
'cascade';
152 $ret = parent::formatParametersForApi();
153 if ( isset(
$ret[
'details'] ) && is_array(
$ret[
'details'] ) ) {
154 foreach (
$ret[
'details']
as &$detail ) {
155 if ( isset( $detail[
'expiry'] ) ) {
156 $detail[
'expiry'] =
$wgContLang->formatExpiry( $detail[
'expiry'], TS_ISO_8601,
'infinite' );
171 $protectDescription =
'';
173 foreach ( $details
as $param ) {
178 $action = $this->context->msg(
'restriction-' . $param[
'type'] )->escaped();
180 $protectionLevel = $param[
'level'];
182 $message = $this->context->msg(
'protect-level-' . $protectionLevel );
183 if ( $message->isDisabled() ) {
185 $restrictions = $this->context->msg(
"protect-fallback", $protectionLevel )->parse();
187 $restrictions = $message->escaped();
190 if ( $protectDescription !==
'' ) {
191 $protectDescription .= $this->context->msg(
'word-separator' )->escaped();
194 $protectDescription .= $this->context->msg(
'protect-summary-desc' )
195 ->params( $action, $restrictions, $expiryText )->escaped();
198 return $protectDescription;
203 return $this->context->msg(
'protect-expiry-indefinite' )->text();
205 $lang = $this->context->getLanguage();
206 $user = $this->context->getUser();
207 return $this->context->msg(
208 'protect-expiring-local',
please add to it if you re going to add events to the MediaWiki code where normally authentication against an external auth plugin would be creating a account $user
static newFromText( $text, $defaultNamespace=NS_MAIN)
Create a new Title from text, such as what one would find in a link.
if(!isset( $args[0])) $lang
getParameters()
Get the extra parameters stored for this message.
design txt This is a brief overview of the new design More thorough and up to date information is available on the documentation wiki at etc Handles the details of getting and saving to the user table of the and dealing with sessions and cookies OutputPage Encapsulates the entire HTML page that will be sent in response to any server request It is used by calling its functions to add text
as see the revision history and available at free of to any person obtaining a copy of this software and associated documentation to deal in the Software without including without limitation the rights to use
injection txt This is an overview of how MediaWiki makes use of dependency injection The design described here grew from the discussion of RFC T384 The term dependency this means that anything an object needs to operate should be injected from the the object itself should only know narrow no concrete implementation of the logic it relies on The requirement to inject everything typically results in an architecture that based on two main types of and essentially stateless service objects that use other service objects to operate on the value objects As of the beginning MediaWiki is only starting to use the DI approach Much of the code still relies on global state or direct resulting in a highly cyclical dependency which acts as the top level factory for services in MediaWiki which can be used to gain access to default instances of various services MediaWikiServices however also allows new services to be defined and default services to be redefined Services are defined or redefined by providing a callback the instantiator that will return a new instance of the service When it will create an instance of MediaWikiServices and populate it with the services defined in the files listed by thereby bootstrapping the DI framework Per $wgServiceWiringFiles lists includes ServiceWiring php
namespace and then decline to actually register it file or subcat img or subcat $title
when a variable name is used in a it is silently declared as a new masking the global
wfIsInfinity( $str)
Determine input string is represents as infinity.
null means default in associative array with keys and values unescaped Should be merged with default with a value of false meaning to suppress the attribute in associative array with keys and values unescaped noclasses & $ret
getSubtype()
The log subtype.
This document is intended to provide useful advice for parties seeking to redistribute MediaWiki to end users It s targeted particularly at maintainers for Linux since it s been observed that distribution packages of MediaWiki often break We ve consistently had to recommend that users seeking support use official tarballs instead of their distribution s and this often solves whatever problem the user is having It would be nice if this could such as
injection txt This is an overview of how MediaWiki makes use of dependency injection The design described here grew from the discussion of RFC T384 The term dependency this means that anything an object needs to operate should be injected from the the object itself should only know narrow no concrete implementation of the logic it relies on The requirement to inject everything typically results in an architecture that based on two main types of and essentially stateless service objects that use other service objects to operate on the value objects As of the beginning MediaWiki is only starting to use the DI approach Much of the code still relies on global state or direct resulting in a highly cyclical dependency MediaWikiServices
the array() calling protocol came about after MediaWiki 1.4rc1.
this class mediates it Skin Encapsulates a look and feel for the wiki All of the functions that render HTML and make choices about how to render it are here and are called from various other places when and is meant to be subclassed with other skins that may override some of its functions The User object contains a reference to a and so rather than having a global skin object we just rely on the global User and get the skin with $wgUser and also has some character encoding functions and other locale stuff The current user interface language is instantiated as and the content language as $wgContLang