36 $this->
namespaces = MWNamespace::getContentNamespaces();
37 parent::__construct( $name );
59 if ( is_string( $par ) ) {
67 if ( is_null( $title ) ) {
76 $redirectParam = $this->
isRedirect() ? [
'redirect' =>
'no' ] : [];
92 $nsNames[] = $this->
msg(
'blanknamespace' )->plain();
110 'SpecialRandomGetRandomTitle',
111 [ &$randstr, &$this->isRedir, &$this->
namespaces, &$this->extra, &$title ]
130 return Title::makeTitleSafe( $row->page_namespace, $row->page_title );
139 $conds = array_merge( [
141 'page_is_redirect' => $redirect,
142 'page_random >= ' . $randstr
147 Hooks::run(
'RandomPageQuery', [ &
$tables, &$conds, &$joinConds ] );
151 'fields' => [
'page_title',
'page_namespace' ],
154 'ORDER BY' =>
'page_random',
157 'join_conds' => $joinConds
to move a page</td >< td > &*You are moving the page across namespaces
wfRandom()
Get a random decimal value between 0 and 1, in a way not likely to give duplicate values for any real...
wfGetDB( $db, $groups=[], $wiki=false)
Get a Database object.
if(defined( 'MW_SETUP_CALLBACK')) $fname
Customization point after all loading (constants, functions, classes, DefaultSettings,...
Special page to direct the user to a random page.
getNsList()
Get a comma-delimited list of namespaces we don't have any pages in.
getRandomTitle()
Choose a random title.
__construct( $name='Randompage')
selectRandomPageFromDB( $randstr, $fname=__METHOD__)
execute( $par)
Default execute method Checks user permissions.
getGroupName()
Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-gro...
Parent class for all special pages.
getName()
Get the name of this Special Page.
setHeaders()
Sets headers - this should be called from the execute() method of all derived classes!
getOutput()
Get the OutputPage being used for this instance.
msg( $key)
Wrapper around wfMessage that sets the current context.
getRequest()
Get the WebRequest being used for this instance.
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 local content language as $wgContLang
this hook is for auditing only RecentChangesLinked and Watchlist RecentChangesLinked and Watchlist Do not use this to implement individual filters if they are compatible with the ChangesListFilter and ChangesListFilterGroup structure use sub classes of those in conjunction with the ChangesListSpecialPageStructuredFilters hook This hook can be used to implement filters that do not implement that or custom behavior that is not an individual filter e g Watchlist & $tables
namespace and then decline to actually register it file or subcat img or subcat $title
null for the local wiki Added should default to null in handler for backwards compatibility add a value to it if you want to add a cookie that have to vary cache options can modify $query