Go to the documentation of this file.
34 global $wgAllowDisplayTitle, $wgAllowSlowParserFunctions;
36 # Syntax for arguments (see self::setFunctionHook):
37 # "name for lookup in localized magic words array",
39 # optional SFH_NO_HASH to omit the hash from calls (e.g. {{int:...}}
40 # instead of {{#int:...}})
41 $noHashFunctions =
array(
42 'ns',
'nse',
'urlencode',
'lcfirst',
'ucfirst',
'lc',
'uc',
43 'localurl',
'localurle',
'fullurl',
'fullurle',
'canonicalurl',
44 'canonicalurle',
'formatnum',
'grammar',
'gender',
'plural',
45 'numberofpages',
'numberofusers',
'numberofactiveusers',
46 'numberofarticles',
'numberoffiles',
'numberofadmins',
47 'numberingroup',
'numberofedits',
'numberofviews',
'language',
48 'padleft',
'padright',
'anchorencode',
'defaultsort',
'filepath',
49 'pagesincategory',
'pagesize',
'protectionlevel',
50 'namespacee',
'namespacenumber',
'talkspace',
'talkspacee',
51 'subjectspace',
'subjectspacee',
'pagename',
'pagenamee',
52 'fullpagename',
'fullpagenamee',
'rootpagename',
'rootpagenamee',
53 'basepagename',
'basepagenamee',
'subpagename',
'subpagenamee',
54 'talkpagename',
'talkpagenamee',
'subjectpagename',
55 'subjectpagenamee',
'pageid',
'revisionid',
'revisionday',
56 'revisionday2',
'revisionmonth',
'revisionmonth1',
'revisionyear',
57 'revisiontimestamp',
'revisionuser',
'cascadingsources',
59 foreach ( $noHashFunctions
as $func ) {
65 $parser->setFunctionHook(
'special',
array( __CLASS__,
'special' ) );
66 $parser->setFunctionHook(
'speciale',
array( __CLASS__,
'speciale' ) );
68 $parser->setFunctionHook(
'formatdate',
array( __CLASS__,
'formatDate' ) );
70 if ( $wgAllowDisplayTitle ) {
73 if ( $wgAllowSlowParserFunctions ) {
84 if ( strval( $part1 ) !==
'' ) {
85 $args = array_slice( func_get_args(), 2 );
86 $message =
wfMessage( $part1,
$args )->inLanguage(
$parser->getOptions()->getUserLangObj() )->plain();
87 return array( $message,
'noparse' =>
false );
89 return array(
'found' =>
false );
101 $lang =
$parser->getFunctionLang();
104 $date = trim( $date );
106 $pref =
$parser->getOptions()->getDateFormat();
110 if ( $pref ==
'default' && $defaultPref ) {
111 $pref = $defaultPref;
114 $date = $df->reformat( $pref, $date,
array(
'match-whole' ) );
120 if ( intval( $part1 ) || $part1 ==
"0" ) {
121 $index = intval( $part1 );
123 $index =
$wgContLang->getNsIndex( str_replace(
' ',
'_', $part1 ) );
125 if ( $index !==
false ) {
128 return array(
'found' =>
false );
134 if ( is_string(
$ret ) ) {
161 $func =
'wfUrlencode';
162 $s = str_replace(
' ',
'_',
$s );
167 $func =
'rawurlencode';
175 return $parser->markerSkipCallback(
$s, $func );
214 if ( !is_string( $temp ) ) {
217 return htmlspecialchars( $temp );
227 if ( !is_string( $temp ) ) {
230 return htmlspecialchars( $temp );
244 # Due to order of execution of a lot of bits, the values might be encoded
245 # before arriving here; if that's true, then the title can't be created
246 # and the variable will fail. If we can't get a decent title from the first
247 # attempt, url-decode and try for a second.
248 if ( is_null(
$title ) ) {
251 if ( !is_null(
$title ) ) {
252 # Convert NS_MEDIA -> NS_FILE
256 if ( !is_null( $arg ) ) {
257 $text =
$title->$func( $arg );
263 return array(
'found' =>
false );
274 if ( self::matchAgainstMagicword(
'rawsuffix', $arg ) ) {
275 $func =
array(
$parser->getFunctionLang(),
'parseFormattedNumber' );
276 } elseif ( self::matchAgainstMagicword(
'nocommafysuffix', $arg ) ) {
277 $func =
array(
$parser->getFunctionLang(),
'formatNumNoSeparators' );
279 $func =
array(
$parser->getFunctionLang(),
'formatNum' );
281 return $parser->markerSkipCallback( $num, $func );
291 $word =
$parser->killMarkers( $word );
292 return $parser->getFunctionLang()->convertGrammar( $word, $case );
302 $forms = array_slice( func_get_args(), 2 );
305 if ( count( $forms ) === 0 ) {
308 } elseif ( count( $forms ) === 1 ) {
313 $username = trim( $username );
322 $username =
$title->getText();
329 } elseif ( $username ===
'' &&
$parser->getOptions()->getInterfaceMessage() ) {
332 $ret =
$parser->getFunctionLang()->gender( $gender, $forms );
343 $forms = array_slice( func_get_args(), 2 );
344 $text =
$parser->getFunctionLang()->parseFormattedNumber( $text );
345 settype( $text, ctype_digit( $text ) ?
'int' :
'float' );
346 return $parser->getFunctionLang()->convertPlural( $text, $forms );
358 global $wgRestrictDisplayTitle;
361 $text =
$parser->doQuotes( $text );
364 $text = preg_replace(
'/' . preg_quote(
$parser->uniqPrefix(),
'/' ) .
'.*?'
365 . preg_quote( Parser::MARKER_SUFFIX,
'/' ) .
'/',
'', $text );
369 $bad =
array(
'h1',
'h2',
'h3',
'h4',
'h5',
'h6',
'div',
'blockquote',
'ol',
'ul',
'li',
'hr',
370 'table',
'tr',
'th',
'td',
'dl',
'dd',
'caption',
'p',
'ruby',
'rb',
'rt',
'rp',
'br' );
373 if ( $wgRestrictDisplayTitle ) {
374 $htmlTagsCallback =
function ( &
$params ) {
377 if ( isset( $decoded[
'style'] ) ) {
382 if ( preg_match(
'/(display|user-select|visibility)\s*:/i', $decoded[
'style'] ) ) {
383 $decoded[
'style'] =
'/* attempt to bypass $wgRestrictDisplayTitle */';
390 $htmlTagsCallback =
null;
399 if ( !$wgRestrictDisplayTitle ) {
400 $parser->mOutput->setDisplayTitle( $text );
402 $parser->mOutput->setDisplayTitle( $text );
421 return $mwObject->matchStartToEnd(
$value );
425 if ( self::matchAgainstMagicword(
'rawsuffix', $raw ) ) {
454 global $wgDisableCounters;
473 if ( is_null(
$t ) ) {
476 return str_replace(
'_',
' ',
$t->getNsText() );
480 if ( is_null(
$t ) ) {
487 if ( is_null(
$t ) ) {
490 return $t->getNamespace();
494 if ( is_null(
$t ) || !
$t->canTalk() ) {
497 return str_replace(
'_',
' ',
$t->getTalkNsText() );
501 if ( is_null(
$t ) || !
$t->canTalk() ) {
508 if ( is_null(
$t ) ) {
511 return str_replace(
'_',
' ',
$t->getSubjectNsText() );
515 if ( is_null(
$t ) ) {
528 if ( is_null(
$t ) ) {
535 if ( is_null(
$t ) ) {
542 if ( is_null(
$t ) || !
$t->canTalk() ) {
549 if ( is_null(
$t ) || !
$t->canTalk() ) {
556 if ( is_null(
$t ) ) {
563 if ( is_null(
$t ) ) {
570 if ( is_null(
$t ) ) {
577 if ( is_null(
$t ) ) {
584 if ( is_null(
$t ) ) {
591 if ( is_null(
$t ) ) {
598 if ( is_null(
$t ) || !
$t->canTalk() ) {
605 if ( is_null(
$t ) || !
$t->canTalk() ) {
612 if ( is_null(
$t ) ) {
619 if ( is_null(
$t ) ) {
636 'pagesincategory_all',
637 'pagesincategory_pages',
638 'pagesincategory_subcats',
639 'pagesincategory_files'
645 if ( self::matchAgainstMagicword(
'rawsuffix', $arg1 ) ) {
655 $type =
'pagesincategory_all';
670 $allCount = $subcatCount = $fileCount = $pagesCount = 0;
671 if (
$parser->incrementExpensiveFunctionCount() ) {
674 $allCount = (int)$category->getPageCount();
675 $subcatCount = (int)$category->getSubcatCount();
676 $fileCount = (int)$category->getFileCount();
677 $pagesCount = $allCount - $subcatCount - $fileCount;
680 $cache[
$name][
'pagesincategory_pages'] = $pagesCount;
681 $cache[
$name][
'pagesincategory_subcats'] = $subcatCount;
682 $cache[
$name][
'pagesincategory_files'] = $fileCount;
701 if ( !is_object(
$title ) ) {
707 $length =
$rev ?
$rev->getSize() : 0;
725 if ( !( $titleObject instanceof
Title ) ) {
726 $titleObject =
$parser->mTitle;
728 if ( $titleObject->areRestrictionsLoaded() ||
$parser->incrementExpensiveFunctionCount() ) {
729 $restrictions = $titleObject->getRestrictions( strtolower(
$type ) );
730 # Title::getRestrictions returns an array, its possible it may have
731 # multiple values in the future
732 return implode( $restrictions,
',' );
745 $code = strtolower( $code );
746 $inLanguage = strtolower( $inLanguage );
748 return $lang !==
'' ? $lang :
wfBCP47( $code );
755 static function pad(
$parser, $string, $length, $padding =
'0', $direction = STR_PAD_RIGHT ) {
756 $padding =
$parser->killMarkers( $padding );
757 $lengthOfPadding = mb_strlen( $padding );
758 if ( $lengthOfPadding == 0 ) {
762 # The remaining length to add counts down to 0 as padding is added
763 $length = min( $length, 500 ) - mb_strlen( $string );
764 # $finalPadding is just $padding repeated enough times so that
765 # mb_strlen( $string ) + mb_strlen( $finalPadding ) == $length
767 while ( $length > 0 ) {
768 # If $length < $lengthofPadding, truncate $padding so we get the
769 # exact length desired.
770 $finalPadding .= mb_substr( $padding, 0, $length );
771 $length -= $lengthOfPadding;
774 if ( $direction == STR_PAD_LEFT ) {
775 return $finalPadding . $string;
777 return $string . $finalPadding;
795 $text =
$parser->killMarkers( $text );
796 return (
string)substr(
$parser->guessSectionNameFromWikiText( $text ), 1 );
803 return $title->getPrefixedText();
830 $text = trim( $text );
831 if ( strlen( $text ) == 0 ) {
834 $old =
$parser->getCustomDefaultSort();
835 if ( $old ===
false || $arg !==
'defaultsort_noreplace' ) {
836 $parser->setDefaultSort( $text );
839 if ( $old ===
false || $old == $text || $arg ) {
842 $converter =
$parser->getConverterLanguage()->getConverter();
843 return '<span class="error">' .
848 )->inContentLanguage()->text() .
858 if ( $argA ==
'nowiki' ) {
861 $parsedWidthParam =
$parser->parseWidthParam( $argB );
864 $parsedWidthParam =
$parser->parseWidthParam( $argA );
865 $isNowiki = ( $argB ==
'nowiki' );
869 $url =
$file->getFullUrl();
872 if ( count( $parsedWidthParam ) ) {
873 $mto =
$file->transform( $parsedWidthParam );
875 if ( $mto && !$mto->isError() ) {
881 return array( $url,
'nowiki' =>
true );
894 if ( !count(
$args ) ) {
897 $tagName = strtolower( trim( $frame->expand( array_shift(
$args ) ) ) );
899 if ( count(
$args ) ) {
900 $inner = $frame->expand( array_shift(
$args ) );
905 $stripList =
$parser->getStripList();
906 if ( !in_array( $tagName, $stripList ) ) {
907 return '<span class="error">' .
908 wfMessage(
'unknown_extension_tag', $tagName )->inContentLanguage()->text() .
912 $attributes =
array();
914 $bits = $arg->splitArg();
915 if ( strval( $bits[
'index'] ) ===
'' ) {
917 $value = trim( $frame->expand( $bits[
'value'] ) );
918 if ( preg_match(
'/^(?:["\'](.+)["\']|""|\'\')$/s',
$value, $m ) ) {
919 $value = isset( $m[1] ) ? $m[1] :
'';
928 'attributes' => $attributes,
929 'close' =>
"</$tagName>",
949 if ( is_null(
$title ) ) {
956 $parserRev =
$parser->getRevisionObject();
957 if ( $parserRev && $parserRev->isCurrent() ) {
959 $parser->getOutput()->setFlag(
'vary-revision' );
960 wfDebug( __METHOD__ .
": use current revision from parser, setting vary-revision...\n" );
966 $page =
$title->getPrefixedDBkey();
968 if ( array_key_exists( $page,
$cache ) ) {
971 if (
$parser->incrementExpensiveFunctionCount() ) {
973 $pageID =
$rev ?
$rev->getPage() : 0;
978 $parser->getOutput()->addTemplate(
$title, $pageID, $revID );
994 if ( is_null(
$t ) ) {
998 if (
$t->equals(
$parser->getTitle() ) ) {
1000 return $t->getArticleID();
1004 if ( !
$t->canExist() ||
$t->isExternal() ) {
1010 $pdbk =
$t->getPrefixedDBkey();
1011 $id = $linkCache->getGoodLinkID( $pdbk );
1016 if ( $linkCache->isBadLink( $pdbk ) ) {
1022 if (
$parser->incrementExpensiveFunctionCount() ) {
1023 $id =
$t->getArticleID();
1038 if ( is_null(
$t ) ) {
1054 if ( is_null(
$t ) ) {
1070 if ( is_null(
$t ) ) {
1086 if ( is_null(
$t ) ) {
1102 if ( is_null(
$t ) ) {
1118 if ( is_null(
$t ) ) {
1134 if ( is_null(
$t ) ) {
1150 if ( is_null(
$t ) ) {
1155 return $rev ?
$rev->getUserText() :
'';
1172 if ( !( $titleObject instanceof
Title ) ) {
1173 $titleObject =
$parser->mTitle;
1175 if ( $titleObject->areCascadeProtectionSourcesLoaded()
1176 ||
$parser->incrementExpensiveFunctionCount()
1179 $sources = $titleObject->getCascadeProtectionSources();
1180 foreach ( $sources[0]
as $sourceTitle ) {
1181 $names[] = $sourceTitle->getPrefixedText();
1183 return implode( $names,
'|' );
static getDefaultOption( $opt)
Get a given default option value.
static & makeTitle( $ns, $title, $fragment='', $interwiki='')
Create a new Title from a namespace index and a DB key.
Class for handling an array of magic words.
static newFromText( $text, $defaultNamespace=NS_MAIN)
Create a new Title from text, such as what one would find in a link.
wfBCP47( $code)
Get the normalised IETF language tag See unit test for examples.
skin txt MediaWiki includes four core it has been set as the default in MediaWiki since the replacing Monobook it had been been the default skin since before being replaced by Vector largely rewritten in while keeping its appearance Several legacy skins were removed in the as the burden of supporting them became too heavy to bear Those in etc for skin dependent CSS etc for skin dependent JavaScript These can also be customised on a per user by etc This feature has led to a wide variety of user styles becoming that gallery is a good place to ending in php
static matchAgainstMagicword( $magicword, $value)
Matches the given value against the value of given magic word.
static pad( $parser, $string, $length, $padding='0', $direction=STR_PAD_RIGHT)
Unicode-safe str_pad with the restriction that $length is forced to be <= 500.
static numberofactiveusers( $parser, $raw=null)
static pageid( $parser, $title=null)
Get the pageid of a specified page.
static talkpagename( $parser, $title=null)
static rootpagename( $parser, $title=null)
static tagObj( $parser, $frame, $args)
Parser function to extension tag adaptor.
static pagesize( $parser, $page='', $raw=null)
Return the size of the given page, or 0 if it's nonexistent.
wfProfileIn( $functionname)
Begin profiling of a function.
static rootpagenamee( $parser, $title=null)
static protectionlevel( $parser, $type='', $title='')
Returns the requested protection level for the current page.
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
wfUrlencode( $s)
We want some things to be included as literal characters in our title URLs for prettiness,...
static numberingroup( $group)
Find the number of users in a given user group.
static & get( $id)
Factory: creates an object representing an ID.
static nse( $parser, $part1='')
static revisionmonth1( $parser, $title=null)
Get the month from the last revision of a specified page.
static newFromName( $name, $validate='valid')
Static factory method for creation from username.
static safeEncodeTagAttributes( $assoc_array)
Build a partial tag string from an associative array of attribute names and values as returned by dec...
static getTitleFor( $name, $subpage=false, $fragment='')
Get a localised Title object for a specified special page name.
static namespacenumber( $parser, $title=null)
static talkspace( $parser, $title=null)
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
static grammar( $parser, $case='', $word='')
static stripAllTags( $text)
Take a fragment of (potentially invalid) HTML and return a version with any tags removed,...
static defaultsort( $parser, $text, $uarg='')
static revisionday( $parser, $title=null)
Get the day from the last revision of a specified page.
static pagename( $parser, $title=null)
Functions to get and normalize pagenames, corresponding to the magic words of the same names.
static revisionid( $parser, $title=null)
Get the id from the last revision of a specified page.
static talkspacee( $parser, $title=null)
to move a page</td >< td > &*You are moving the page across *A non empty talk page already exists under the new or *You uncheck the box below In those you will have to move or merge the page manually if desired</td >< td > be sure to &You are responsible for making sure that links continue to point where they are supposed to go Note that the page will &a page at the new title
static localurle( $parser, $s='', $arg=null)
static getCachedRevisionObject( $parser, $title=null)
Fetched the current revision of the given title and return this.
static displaytitle( $parser, $text='')
Override the title of the page when viewed, provided we've been given a title which will normalise to...
static plural( $parser, $text='')
static numberofpages( $parser, $raw=null)
static basepagenamee( $parser, $title=null)
do that in ParserLimitReportFormat instead $parser
static revisionyear( $parser, $title=null)
Get the year from the last revision of a specified page.
static numberofviews( $parser, $raw=null)
wfProfileOut( $functionname='missing')
Stop profiling of a function.
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 just before the function returns a value If you return an< a > element with HTML attributes $attribs and contents $html will be returned If you return $ret will be returned and may include noclasses after processing after in associative array form externallinks including delete and has completed for all link tables default is conds Array Extra conditions for the No matching items in log is displayed if loglist is empty msgKey Array If you want a nice box with a set this to the key of the message First element is the message additional optional elements are parameters for the key that are processed with wfMessage() -> params() ->parseAsBlock() - offset Set to overwrite offset parameter in $wgRequest set to '' to unset offset - wrap String Wrap the message in html(usually something like "<
static mwnamespace( $parser, $title=null)
Given a title, return the namespace name that would be given by the corresponding magic word Note: fu...
static fullurle( $parser, $s='', $arg=null)
the array() calling protocol came about after MediaWiki 1.4rc1.
List of Api Query prop modules.
static numberofedits( $parser, $raw=null)
static revisionday2( $parser, $title=null)
Get the day with leading zeros from the last revision of a specified page.
static fullurl( $parser, $s='', $arg=null)
static ucfirst( $parser, $s='')
when a variable name is used in a it is silently declared as a new masking the global
static fullpagenamee( $parser, $title=null)
magicword txt Magic Words are some phrases used in the wikitext They are used for two that looks like templates but that don t accept any parameter *Parser functions(like {{fullurl:...}}, {{#special:...}}) $magicWords['en']
static gender( $parser, $username)
static pagenamee( $parser, $title=null)
static ns( $parser, $part1='')
static subjectpagename( $parser, $title=null)
static language( $parser, $code='', $inLanguage='')
Gives language names.
static revisiontimestamp( $parser, $title=null)
Get the timestamp from the last revision of a specified page.
deferred txt A few of the database updates required by various functions here can be deferred until after the result page is displayed to the user For updating the view updating the linked to tables after a etc PHP does not yet have any way to tell the server to actually return and disconnect while still running these but it might have such a feature in the future We handle these by creating a deferred update object and putting those objects on a global list
static newFromTitle( $title)
Factory function.
static urlencode( $parser, $s='', $arg=null)
urlencodes a string according to one of three patterns: (bug 22474)
static formatDate( $parser, $date, $defaultPref=null)
static newFromTitle( $title, $id=0, $flags=0)
Load either the current, or a specified, revision that's attached to a given title.
wfDebug( $text, $dest='all')
Sends a line to the debug log if enabled or, optionally, to a comment in output.
static makeTitleSafe( $ns, $title, $fragment='', $interwiki='')
Create a new Title from a namespace index and a DB key.
presenting them properly to the user as errors is done by the caller $title
static fullpagename( $parser, $title=null)
Allows to change the fields on the form that will be generated $name
static formatRaw( $num, $raw)
static padleft( $parser, $string='', $length=0, $padding='0')
static padright( $parser, $string='', $length=0, $padding='0')
static newFromURL( $url)
THIS IS NOT THE FUNCTION YOU WANT.
static revisionmonth( $parser, $title=null)
Get the month with leading zeros from the last revision of a specified page.
static resolveAlias( $alias)
Given a special page name with a possible subpage, return an array where the first element is the spe...
wfEscapeWikiText( $text)
Escapes the given text so that it may be output using addWikiText() without any linking,...
static subjectspacee( $parser, $title=null)
static speciale( $parser, $text)
static fetchLanguageName( $code, $inLanguage=null, $include='all')
static urlFunction( $func, $s='', $arg=null)
static lc( $parser, $s='')
static subjectspace( $parser, $title=null)
static subjectpagenamee( $parser, $title=null)
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
if(PHP_SAPI !='cli') $file
presenting them properly to the user as errors is done by the caller return true use this to change the list i e etc $rev
Represents a title within MediaWiki.
static numberofadmins( $parser, $raw=null)
static cascadingsources( $parser, $title='')
Returns the sources of any cascading protection acting on a specified page.
static anchorencode( $parser, $text)
static uc( $parser, $s='')
static special( $parser, $text)
static subpagenamee( $parser, $title=null)
static filepath( $parser, $name='', $argA='', $argB='')
static namespacee( $parser, $title=null)
static numberofarticles( $parser, $raw=null)
if the prop value should be in the metadata multi language array format
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
wfFindFile( $title, $options=array())
Find a file.
Various core parser functions, registered in Parser::firstCallInit()
static subpagename( $parser, $title=null)
static revisionuser( $parser, $title=null)
Get the user from the last revision of a specified page.
static numberingroup( $parser, $name='', $raw=null)
static normalizeCharReferences( $text)
Ensure that any entities and character references are legal for XML and XHTML specifically.
static decodeTagAttributes( $text)
Return an associative array of attribute names and values from a partial tag string.
static numberofusers( $parser, $raw=null)
static pagesincategory( $parser, $name='', $arg1=null, $arg2=null)
Return the number of pages, files or subcats in the given category, or 0 if it's nonexistent.
static numberoffiles( $parser, $raw=null)
static pagesinnamespace( $parser, $namespace=0, $raw=null)
static formatnum( $parser, $num='', $arg=null)
static lcfirst( $parser, $s='')
static canonicalurl( $parser, $s='', $arg=null)
static checkCss( $value)
Pick apart some CSS and check it for forbidden or unsafe structures.
static & singleton()
Get an instance of this class.
static getLocalInstance( $ts=false)
Get a timestamp instance in the server local timezone ($wgLocaltimezone)
static intFunction( $parser, $part1='')
static basepagename( $parser, $title=null)
static canonicalurle( $parser, $s='', $arg=null)
wfExpandUrl( $url, $defaultProto=PROTO_CURRENT)
Expand a potentially local URL to a fully-qualified URL.
static localurl( $parser, $s='', $arg=null)
static removeHTMLtags( $text, $processCallback=null, $args=array(), $extratags=array(), $removetags=array())
Cleans up HTML, removes dangerous tags and attributes, and removes HTML comments.
static talkpagenamee( $parser, $title=null)