|
MediaWiki
REL1_20
|
Shows a generic "user is not logged in" error page. More...


Public Member Functions | |
| __construct ($reasonMsg= 'exception-nologin-text', $titleMsg= 'exception-nologin', $params=null) | |
Shows a generic "user is not logged in" error page.
This is essentially an ErrorPageError exception which by default use the 'exception-nologin' as a title and 'exception-nologin-text' for the message.
if( $user->isAnon ) { throw new UserNotLoggedIn(); }
Please note the parameters are mixed up compared to ErrorPageError, this is done to be able to simply specify a reason whitout overriding the default title.
if( $user->isAnon ) { throw new UserNotLoggedIn( 'action-require-loggedin' ); }
Definition at line 528 of file Exception.php.
| UserNotLoggedIn::__construct | ( | $ | reasonMsg = 'exception-nologin-text', |
| $ | titleMsg = 'exception-nologin', |
||
| $ | params = null |
||
| ) |
| $reasonMsg | A message key containing the reason for the error. Optional, default: 'exception-nologin-text' |
| $titleMsg | A message key to set the page title. Optional, default: 'exception-nologin' |
| $params | Parameters to wfMessage(). Optiona, default: null |
Reimplemented from ErrorPageError.
Definition at line 538 of file Exception.php.
References ErrorPageError\$params.