|
MediaWiki master
|
Reference to a locally-hosted wiki. More...
Public Member Functions | |
| __construct (string $canonicalServer, string $path, ?string $server=null) | |
| getCanonicalServer () | |
| Get the canonical server (i.e. | |
| getCanonicalUrl ( $page, $fragmentId=null) | |
| Create a full canonical URL to a page on the given wiki. | |
| getDisplayName () | |
| Extract the server name from wgCanonicalServer. | |
| getFullUrl ( $page, $fragmentId=null) | |
| Create a full URL like Title::getFullURL() to a page, based on $wgServer. | |
| getUrl ( $page, $fragmentId=null) | |
| Alias for getCanonicalUrl(), for backwards compatibility. | |
Reference to a locally-hosted wiki.
Definition at line 14 of file WikiReference.php.
| MediaWiki\WikiMap\WikiReference::__construct | ( | string | $canonicalServer, |
| string | $path, | ||
| ?string | $server = null ) |
| string | $canonicalServer | |
| string | $path | |
| null | string | $server |
Definition at line 27 of file WikiReference.php.
References $path.
| MediaWiki\WikiMap\WikiReference::getCanonicalServer | ( | ) |
Get the canonical server (i.e.
$wgCanonicalServer)
Definition at line 38 of file WikiReference.php.
| MediaWiki\WikiMap\WikiReference::getCanonicalUrl | ( | $page, | |
| $fragmentId = null ) |
Create a full canonical URL to a page on the given wiki.
| string | $page | Page name (must be normalised before calling this function!) |
| string | null | $fragmentId |
Definition at line 60 of file WikiReference.php.
Referenced by MediaWiki\WikiMap\WikiReference\getUrl().
| MediaWiki\WikiMap\WikiReference::getDisplayName | ( | ) |
Extract the server name from wgCanonicalServer.
Definition at line 47 of file WikiReference.php.
| MediaWiki\WikiMap\WikiReference::getFullUrl | ( | $page, | |
| $fragmentId = null ) |
Create a full URL like Title::getFullURL() to a page, based on $wgServer.
This is similar to what Title::getFullURL() would produce when called locally on the wiki, and may differ from the canonical URL, depending on site configuration, as it uses $wgServer instead of $wgCanonicalServer.
| string | $page | Page name (must be normalized before calling this function!) |
| string | null | $fragmentId |
Definition at line 86 of file WikiReference.php.
| MediaWiki\WikiMap\WikiReference::getUrl | ( | $page, | |
| $fragmentId = null ) |
Alias for getCanonicalUrl(), for backwards compatibility.
| string | $page | |
| string | null | $fragmentId |
Definition at line 71 of file WikiReference.php.
References MediaWiki\WikiMap\WikiReference\getCanonicalUrl().