MediaWiki  1.23.2
SpecialMyRedirectPages.php
Go to the documentation of this file.
1 <?php
33  function __construct() {
34  parent::__construct( 'Mypage' );
35  }
36 
37  function getRedirect( $subpage ) {
38  if ( strval( $subpage ) !== '' ) {
39  return Title::makeTitle( NS_USER, $this->getUser()->getName() . '/' . $subpage );
40  } else {
41  return Title::makeTitle( NS_USER, $this->getUser()->getName() );
42  }
43  }
44 }
45 
52  function __construct() {
53  parent::__construct( 'Mytalk' );
54  }
55 
56  function getRedirect( $subpage ) {
57  if ( strval( $subpage ) !== '' ) {
58  return Title::makeTitle( NS_USER_TALK, $this->getUser()->getName() . '/' . $subpage );
59  } else {
60  return Title::makeTitle( NS_USER_TALK, $this->getUser()->getName() );
61  }
62  }
63 }
64 
71  function __construct() {
72  parent::__construct( 'Mycontributions' );
73  $this->mAllowedRedirectParams = array( 'limit', 'namespace', 'tagfilter',
74  'offset', 'dir', 'year', 'month', 'feed' );
75  }
76 
77  function getRedirect( $subpage ) {
78  return SpecialPage::getTitleFor( 'Contributions', $this->getUser()->getName() );
79  }
80 }
81 
88  function __construct() {
89  parent::__construct( 'Myuploads' );
90  $this->mAllowedRedirectParams = array( 'limit', 'ilshowall', 'ilsearch' );
91  }
92 
93  function getRedirect( $subpage ) {
94  return SpecialPage::getTitleFor( 'Listfiles', $this->getUser()->getName() );
95  }
96 }
97 
104  function __construct() {
105  parent::__construct( 'AllMyUploads' );
106  $this->mAllowedRedirectParams = array( 'limit', 'ilsearch' );
107  }
108 
109  function getRedirect( $subpage ) {
110  $this->mAddedRedirectParams['ilshowall'] = 1;
111 
112  return SpecialPage::getTitleFor( 'Listfiles', $this->getUser()->getName() );
113  }
114 }
Title\makeTitle
static & makeTitle( $ns, $title, $fragment='', $interwiki='')
Create a new Title from a namespace index and a DB key.
Definition: Title.php:398
SpecialMycontributions\__construct
__construct()
Definition: SpecialMyRedirectPages.php:71
php
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
Definition: skin.txt:62
SpecialAllMyUploads\__construct
__construct()
Definition: SpecialMyRedirectPages.php:104
SpecialAllMyUploads
Special page pointing to current user's uploaded files (including old versions).
Definition: SpecialMyRedirectPages.php:103
SpecialMypage
Special page pointing to current user's user page.
Definition: SpecialMyRedirectPages.php:32
SpecialMypage\getRedirect
getRedirect( $subpage)
If the special page is a redirect, then get the Title object it redirects to.
Definition: SpecialMyRedirectPages.php:37
SpecialMycontributions
Special page pointing to current user's contributions.
Definition: SpecialMyRedirectPages.php:70
SpecialPage\getTitleFor
static getTitleFor( $name, $subpage=false, $fragment='')
Get a localised Title object for a specified special page name.
Definition: SpecialPage.php:74
SpecialPage\getName
getName()
Get the name of this Special Page.
Definition: SpecialPage.php:139
RedirectSpecialPage
Shortcut to construct a special page alias.
Definition: RedirectSpecialPage.php:29
SpecialMyuploads\getRedirect
getRedirect( $subpage)
If the special page is a redirect, then get the Title object it redirects to.
Definition: SpecialMyRedirectPages.php:93
SpecialMytalk\__construct
__construct()
Definition: SpecialMyRedirectPages.php:52
SpecialMycontributions\getRedirect
getRedirect( $subpage)
If the special page is a redirect, then get the Title object it redirects to.
Definition: SpecialMyRedirectPages.php:77
array
the array() calling protocol came about after MediaWiki 1.4rc1.
List of Api Query prop modules.
SpecialPage\getUser
getUser()
Shortcut to get the User executing this instance.
Definition: SpecialPage.php:545
RedirectSpecialArticle
Superclass for any RedirectSpecialPage which redirects the user to a particular article (as opposed t...
Definition: RedirectSpecialPage.php:186
NS_USER_TALK
const NS_USER_TALK
Definition: Defines.php:82
SpecialAllMyUploads\getRedirect
getRedirect( $subpage)
If the special page is a redirect, then get the Title object it redirects to.
Definition: SpecialMyRedirectPages.php:109
SpecialMypage\__construct
__construct()
Definition: SpecialMyRedirectPages.php:33
SpecialMytalk\getRedirect
getRedirect( $subpage)
If the special page is a redirect, then get the Title object it redirects to.
Definition: SpecialMyRedirectPages.php:56
SpecialMytalk
Special page pointing to current user's talk page.
Definition: SpecialMyRedirectPages.php:51
NS_USER
const NS_USER
Definition: Defines.php:81
SpecialMyuploads
Special page pointing to current user's uploaded files.
Definition: SpecialMyRedirectPages.php:87
SpecialMyuploads\__construct
__construct()
Definition: SpecialMyRedirectPages.php:88