MediaWiki
1.23.2
|
Fake title class that triggers an error if any members are called. More...
Public Member Functions | |
areRestrictionsCascading () | |
Returns cascading restrictions for the current article. More... | |
canExist () | |
Is this in a namespace that allows actual pages? More... | |
canTalk () | |
Could this title have a corresponding talk page? More... | |
canUseNoindex () | |
Whether the magic words INDEX and NOINDEX function for this page. More... | |
countRevisionsBetween ( $old, $new) | |
deleteTitleProtection () | |
Remove any title protection due to page existing. More... | |
equals (Title $title) | |
Compare with another title. More... | |
error () | |
escapeFullURL ( $query='', $query2=false) | |
Get an HTML-escaped version of the URL form, suitable for using in a link, including the server name and fragment. More... | |
escapeLocalURL ( $query='', $query2=false) | |
Get an HTML-escaped version of the URL form, suitable for using in a link, without a server name or fragment. More... | |
exists () | |
Check if page exists. More... | |
fixSpecialName () | |
If the Title refers to a special page alias which is not the local default, resolve the alias, and localise the name as necessary. More... | |
getArticleID ( $flags=0) | |
Get the article ID for this Title from the link cache, adding it if necessary. More... | |
getBacklinkCache () | |
Get a backlink cache object. More... | |
getBaseText () | |
Get the base page name without a namespace, i.e. More... | |
getBrokenLinksFrom () | |
Get an array of Title objects referring to non-existent articles linked from this page. More... | |
getCascadeProtectionSources ( $get_pages=true) | |
Cascading protection: Get the source of any cascading restrictions on this page. More... | |
getDBkey () | |
Get the main part with underscores. More... | |
getDefaultNamespace () | |
Get the default namespace index, for when there is no namespace. More... | |
getEarliestRevTime ( $flags=0) | |
Get the oldest revision timestamp of this page. More... | |
getEditURL () | |
Get the edit URL for this Title. More... | |
getEscapedText () | |
Get the HTML-escaped displayable text form. More... | |
getFirstRevision ( $flags=0) | |
Get the first revision of the page. More... | |
getFragment () | |
Get the Title fragment (i.e. the bit after the #) in text form. More... | |
getFragmentForURL () | |
Get the fragment in URL form, including the "#" character if there is one. More... | |
getFullText () | |
Get the prefixed title with spaces, plus any fragment (part beginning with '#') More... | |
getFullURL ( $query='', $variant=false) | |
getIndexTitle () | |
Get title for search index. More... | |
getInternalURL ( $query='', $variant=false) | |
Get the URL form for an internal link. More... | |
getInterwiki () | |
Get the interwiki prefix. More... | |
getLatestRevID ( $flags=0) | |
What is the page_latest field for this page? More... | |
getLength ( $flags=0) | |
What is the length of this page? Uses link cache, adding it if necessary. More... | |
getLinksTo ( $options=array(), $table='pagelinks', $prefix='pl') | |
Get an array of Title objects linking to this Title Also stores the IDs in the link cache. More... | |
getLinkURL ( $query=array(), $variant=false) | |
getLocalURL ( $query='', $variant=false) | |
Get a URL with no fragment or server name (relative URL) from a Title object. More... | |
getNamespace () | |
Get the namespace index, i.e. More... | |
getNamespaceKey ( $prepend='nstab-') | |
Generate strings used for xml 'id' names in monobook tabs. More... | |
getNextRevisionID ( $revId, $flags=0) | |
Get the revision ID of the next revision. More... | |
getNotificationTimestamp ( $user=null) | |
Get the timestamp when this page was updated since the user last saw it. More... | |
getNsText () | |
Get the namespace text. More... | |
getParentCategories () | |
Get categories to which this Title belongs and return an array of categories' names. More... | |
getParentCategoryTree ( $children=array()) | |
Get a tree of parent categories. More... | |
getPartialURL () | |
Get the URL-encoded form of the main part. More... | |
getPrefixedDBkey () | |
Get the prefixed database key form. More... | |
getPrefixedText () | |
Get the prefixed title with spaces. More... | |
getPrefixedURL () | |
Get a URL-encoded title (not an actual URL) including interwiki. More... | |
getPreviousRevisionID ( $revId, $flags=0) | |
Get the revision ID of the previous revision. More... | |
getRedirectsHere ( $ns=null) | |
Get all extant redirects to this Title. More... | |
getRestrictionExpiry ( $action) | |
Get the expiry time for the restriction against a given action. More... | |
getRestrictions ( $action) | |
Accessor/initialisation for mRestrictions. More... | |
getRestrictionTypes () | |
Returns restriction types for the current Title. More... | |
getSkinFromCssJsSubpage () | |
Trim down a .css or .js subpage title to get the corresponding skin name. More... | |
getSquidURLs () | |
Get a list of URLs to purge from the Squid cache when this page changes. More... | |
getSubjectNsText () | |
Get the namespace text of the subject (rather than talk) page. More... | |
getSubjectPage () | |
Get a title object associated with the subject page of this talk page. More... | |
getSubpages ( $limit=-1) | |
Get all subpages of this page. More... | |
getSubpageText () | |
Get the lowest-level subpage name, i.e. More... | |
getSubpageUrlForm () | |
Get a URL-encoded form of the subpage text. More... | |
getTalkNsText () | |
Get the namespace text of the talk page. More... | |
getTalkPage () | |
Get a Title object associated with the talk page of this article. More... | |
getTemplateLinksTo ( $options=array()) | |
Get an array of Title objects using this Title as a template Also stores the IDs in the link cache. More... | |
getText () | |
Get the text form (spaces not underscores) of the main part. More... | |
getTouched ( $db=null) | |
Get the last touched timestamp. More... | |
getUserCaseDBKey () | |
Get the DB key with the initial letter case as specified by the user. More... | |
getUserPermissionsErrors ( $action, $user, $doExpensiveQueries=true, $ignoreErrors=array()) | |
Can $user perform $action on this page? More... | |
hasFragment () | |
Check if a Title fragment is set. More... | |
hasSubpages () | |
Does this have subpages? (Warning, usually requires an extra DB query.) More... | |
invalidateCache () | |
Updates page_touched for this page; called from LinksUpdate.php. More... | |
isAlwaysKnown () | |
Should links to this title be shown as potentially viewable (i.e. More... | |
isCascadeProtected () | |
Cascading protection: Return true if cascading restrictions apply to this page, false if not. More... | |
isContentPage () | |
Is this Title in a namespace which contains content? In other words, is this a content page, for the purposes of calculating statistics, etc? More... | |
isConversionTable () | |
Is this a conversion table for the LanguageConverter? More... | |
isCssJsSubpage () | |
Is this a .css or .js subpage of a user page? More... | |
isCssOrJsPage () | |
Could this page contain custom CSS or JavaScript for the global UI. More... | |
isCssSubpage () | |
Is this a .css subpage of a user page? More... | |
isDeleted () | |
Is there a version of this page in the deletion archive? More... | |
isDeletedQuick () | |
Is there a version of this page in the deletion archive? More... | |
isExternal () | |
Is this Title interwiki? More... | |
isJsSubpage () | |
Is this a .js subpage of a user page? More... | |
isKnown () | |
Does this title refer to a page that can (or might) be meaningfully viewed? In particular, this function may be used to determine if links to the title should be rendered as "bluelinks" (as opposed to "redlinks" to non-existent pages). More... | |
isLocal () | |
Determine whether the object refers to a page within this project. More... | |
isMovable () | |
Would anybody with sufficient privileges be able to move this page? Some pages just aren't movable. More... | |
isNamespaceProtected (User $user) | |
Determines if $user is unable to edit this page because it has been protected by $wgNamespaceProtection. More... | |
isNewPage () | |
Check if this is a new page. More... | |
isProtected ( $action='') | |
Does the title correspond to a protected article? More... | |
isRedirect ( $flags=0) | |
Is this an article that is a redirect page? Uses link cache, adding it if necessary. More... | |
isSemiProtected ( $action='edit') | |
Is this page "semi-protected" - the only protection levels are listed in $wgSemiprotectedRestrictionLevels? More... | |
isSingleRevRedirect () | |
Checks if this page is just a one-rev redirect. More... | |
isSpecial ( $name) | |
Returns true if this title resolves to the named special page. More... | |
isSpecialPage () | |
Returns true if this is a special page. More... | |
isSubpage () | |
Is this a subpage? More... | |
isTalkPage () | |
Is this a talk page of some sort? More... | |
isTrans () | |
Determine whether the object refers to a page within this project and is transcludable. More... | |
isValidMoveOperation (&$nt, $auth=true, $reason='') | |
Check whether a given move operation would be valid. More... | |
isValidMoveTarget ( $nt) | |
Checks if $this can be moved to a given Title. More... | |
isValidRedirectTarget () | |
Check if this Title is a valid redirect target. More... | |
isWatchable () | |
Can this title be added to a user's watchlist? More... | |
loadRestrictions ( $res=null) | |
Load restrictions from the page_restrictions table. More... | |
loadRestrictionsFromRows ( $rows, $oldFashionedRestrictions=null) | |
Compiles list of active page restrictions from both page table (pre 1.10) and page_restrictions table for this existing page. More... | |
moveNoAuth (&$nt) | |
Move this page without authentication. More... | |
moveSubpages ( $nt, $auth=true, $reason='', $createRedirect=true) | |
Move this page's subpages to be subpages of $nt. More... | |
moveTo (&$nt, $auth=true, $reason='', $createRedirect=true) | |
Move a title to a new location. More... | |
pageCond () | |
Get an associative array for selecting this title from the "page" table. More... | |
purgeSquid () | |
Purge all applicable Squid URLs. More... | |
quickUserCan ( $action, $user=null) | |
Can $user perform $action on this page? This skips potentially expensive cascading permission checks as well as avoids expensive error formatting. More... | |
resetArticleID ( $newid) | |
This clears some fields in this object, and clears any associated keys in the "bad links" section of the link cache. More... | |
setFragment ( $fragment) | |
Set the fragment for this title. More... | |
touchLinks () | |
Update page_touched timestamps and send squid purge messages for pages linking to this title. More... | |
updateTitleProtection ( $create_perm, $reason, $expiry) | |
Update the title protection status. More... | |
userCan ( $action, $user=null, $doExpensiveQueries=true) | |
Can $user perform $action on this page? More... | |
userCanEditCssSubpage () | |
userCanEditJsSubpage () | |
userCanRead () | |
Can $wgUser read this page? More... | |
userIsWatching () | |
Is $wgUser watching this page? More... | |
Public Member Functions inherited from Title | |
__construct () | |
Constructor. More... | |
loadFromRow ( $row) | |
Load Title object fields from a DB row. More... | |
getTransWikiID () | |
Returns the DB name of the distant wiki which owns the object. More... | |
getTitleValue () | |
Get a TitleValue object representing this Title. More... | |
getContentModel () | |
Get the page's content model id, see the CONTENT_MODEL_XXX constants. More... | |
hasContentModel ( $id) | |
Convenience method for checking a title's content model name. More... | |
inNamespace ( $ns) | |
Returns true if the title is inside the specified namespace. More... | |
inNamespaces () | |
Returns true if the title is inside one of the specified namespaces. More... | |
hasSubjectNamespace ( $ns) | |
Returns true if the title has the same subject namespace as the namespace specified. More... | |
isMainPage () | |
Is this the mainpage? More... | |
isWikitextPage () | |
Does that page contain wikitext, or it is JS, CSS or whatever? More... | |
__toString () | |
Return a string representation of this title. More... | |
getRootText () | |
Get the root page name text without a namespace, i.e. More... | |
getRootTitle () | |
Get the root page name title, i.e. More... | |
getBaseTitle () | |
Get the base page name title, i.e. More... | |
getSubpage ( $text) | |
Get the title for a subpage of the current page. More... | |
getFullURL ( $query='', $query2=false, $proto=PROTO_RELATIVE) | |
Get a real URL referring to this title, with interwiki link and fragment. More... | |
getLinkURL ( $query='', $query2=false, $proto=PROTO_RELATIVE) | |
Get a URL that's the simplest URL that will be valid to link, locally, to the current Title. More... | |
getCanonicalURL ( $query='', $query2=false) | |
Get the URL for a canonical link, for use in things like IRC and e-mail notifications. More... | |
escapeCanonicalURL ( $query='', $query2=false) | |
HTML-escaped version of getCanonicalURL() More... | |
areCascadeProtectionSourcesLoaded ( $getPages=true) | |
Determines whether cascading protection sources have already been loaded from the database. More... | |
areRestrictionsLoaded () | |
Accessor for mRestrictionsLoaded. More... | |
getAllRestrictions () | |
Accessor/initialisation for mRestrictions. More... | |
flushRestrictions () | |
Flush the protection cache in this object and force reload from the database. More... | |
getLinksFrom ( $options=array(), $table='pagelinks', $prefix='pl') | |
Get an array of Title objects linked from this Title Also stores the IDs in the link cache. More... | |
getTemplateLinksFrom ( $options=array()) | |
Get an array of Title objects used on this Title as a template Also stores the IDs in the link cache. More... | |
isBigDeletion () | |
Check whether the number of revisions of this page surpasses $wgDeleteRevisionsLimit. More... | |
estimateRevisionCount () | |
Get the approximate revision count of this page. More... | |
countRevisionsBetween ( $old, $new, $max=null) | |
Get the number of revisions between the given revision. More... | |
getAuthorsBetween ( $old, $new, $limit, $options=array()) | |
Get the authors between the given revisions or revision IDs. More... | |
countAuthorsBetween ( $old, $new, $limit, $options=array()) | |
Get the number of authors between the given revisions or revision IDs. More... | |
isSubpageOf (Title $title) | |
Check if this title is a subpage of another title. More... | |
hasSourceText () | |
Does this page have source text? More... | |
getDefaultMessageText () | |
Get the default message text or false if the message doesn't exist. More... | |
getCategorySortkey ( $prefix='') | |
Returns the raw sort key to be used for categories, with the specified prefix. More... | |
getPageLanguage () | |
Get the language in which the content of this page is written in wikitext. More... | |
getPageViewLanguage () | |
Get the language in which the content of this page is written when viewed by user. More... | |
getEditNotices ( $oldid=0) | |
Get a list of rendered edit notices for this page. More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from Title | |
static | newFromDBkey ( $key) |
Create a new Title from a prefixed DB key. More... | |
static | newFromTitleValue (TitleValue $titleValue) |
Create a new Title from a TitleValue. More... | |
static | newFromText ( $text, $defaultNamespace=NS_MAIN) |
Create a new Title from text, such as what one would find in a link. More... | |
static | newFromURL ( $url) |
THIS IS NOT THE FUNCTION YOU WANT. More... | |
static | newFromID ( $id, $flags=0) |
Create a new Title from an article ID. More... | |
static | newFromIDs ( $ids) |
Make an array of titles from an array of IDs. More... | |
static | newFromRow ( $row) |
Make a Title object from a DB row. More... | |
static & | makeTitle ( $ns, $title, $fragment='', $interwiki='') |
Create a new Title from a namespace index and a DB key. More... | |
static | makeTitleSafe ( $ns, $title, $fragment='', $interwiki='') |
Create a new Title from a namespace index and a DB key. More... | |
static | newMainPage () |
Create a new Title for the Main Page. More... | |
static | newFromRedirect ( $text) |
Extract a redirect destination from a string and return the Title, or null if the text doesn't contain a valid redirect This will only return the very next target, useful for the redirect table and other checks that don't need full recursion. More... | |
static | newFromRedirectRecurse ( $text) |
Extract a redirect destination from a string and return the Title, or null if the text doesn't contain a valid redirect This will recurse down $wgMaxRedirects times or until a non-redirect target is hit in order to provide (hopefully) the Title of the final destination instead of another redirect. More... | |
static | newFromRedirectArray ( $text) |
Extract a redirect destination from a string and return an array of Titles, or null if the text doesn't contain a valid redirect The last element in the array is the final destination after all redirects have been resolved (up to $wgMaxRedirects times) More... | |
static | nameOf ( $id) |
Get the prefixed DB key associated with an ID. More... | |
static | legalChars () |
Get a regex character class describing the legal characters in a link. More... | |
static | getTitleInvalidRegex () |
Returns a simple regex that will match on characters and sequences invalid in titles. More... | |
static | convertByteClassToUnicodeClass ( $byteClass) |
Utility method for converting a character sequence from bytes to Unicode. More... | |
static | indexTitle ( $ns, $title) |
Get a string representation of a title suitable for including in a search index. More... | |
static | makeName ( $ns, $title, $fragment='', $interwiki='') |
Make a prefixed DB key from a DB key and a namespace index. More... | |
static | escapeFragmentForURL ( $fragment) |
Escape a text fragment, say from a link, for a URL. More... | |
static | compare ( $a, $b) |
Callback for usort() to do title sorts by (namespace, title) More... | |
static | getFilteredRestrictionTypes ( $exists=true) |
Get a filtered list of all restriction types supported by this wiki. More... | |
static | purgeExpiredRestrictions () |
Purge expired restrictions from the page_restrictions table. More... | |
static | capitalize ( $text, $ns=NS_MAIN) |
Capitalize a text string for a title if it belongs to a namespace that capitalizes. More... | |
Public Attributes inherited from Title | |
const | CACHE_MAX = 1000 |
Title::newFromText maintains a cache to avoid expensive re-normalization of commonly used titles. More... | |
const | GAID_FOR_UPDATE = 1 |
Used to be GAID_FOR_UPDATE define. More... | |
$mTextform = '' | |
Cascade restrictions on this page to included templates and images? More... | |
$mUrlform = '' | |
Cascade restrictions on this page to included templates and images? More... | |
$mDbkeyform = '' | |
Cascade restrictions on this page to included templates and images? More... | |
$mUserCaseDBKey | |
Cascade restrictions on this page to included templates and images? More... | |
$mNamespace = NS_MAIN | |
Cascade restrictions on this page to included templates and images? More... | |
$mInterwiki = '' | |
Cascade restrictions on this page to included templates and images? More... | |
$mFragment = '' | |
Cascade restrictions on this page to included templates and images? More... | |
$mArticleID = -1 | |
Cascade restrictions on this page to included templates and images? More... | |
$mLatestID = false | |
Cascade restrictions on this page to included templates and images? More... | |
$mContentModel = false | |
Cascade restrictions on this page to included templates and images? More... | |
$mRestrictions = array() | |
Cascade restrictions on this page to included templates and images? More... | |
$mOldRestrictions = false | |
Cascade restrictions on this page to included templates and images? More... | |
$mCascadeRestriction | |
Cascade restrictions on this page to included templates and images? More... | |
$mCascadingRestrictions | |
Cascade restrictions on this page to included templates and images? More... | |
$mRestrictionsExpiry = array() | |
When do the restrictions on this page expire? More... | |
$mHasCascadingRestrictions | |
Are cascading restrictions in effect on this page? More... | |
$mCascadeSources | |
Where are the cascading restrictions coming from on this page? More... | |
$mRestrictionsLoaded = false | |
Boolean for initialisation on demand. More... | |
$mPrefixedText = null | |
Text form including namespace/interwiki, initialised on demand. More... | |
$mTitleProtection | |
Cached value for getTitleProtection (create protection) More... | |
$mDefaultNamespace = NS_MAIN | |
Cascade restrictions on this page to included templates and images? More... | |
$mWatched = null | |
Cascade restrictions on this page to included templates and images? More... | |
$mLength = -1 | |
Cascade restrictions on this page to included templates and images? More... | |
$mRedirect = null | |
Cascade restrictions on this page to included templates and images? More... | |
$mNotificationTimestamp = array() | |
Cascade restrictions on this page to included templates and images? More... | |
$mHasSubpage | |
Cascade restrictions on this page to included templates and images? More... | |
Protected Member Functions inherited from Title | |
getUserPermissionsErrorsInternal ( $action, $user, $doExpensiveQueries=true, $short=false) | |
Can $user perform $action on this page? This is an internal function, which checks ONLY that previously checked by userCan (i.e. More... | |
validateFileMoveOperation ( $nt) | |
Check if the requested move target is a valid file move target. More... | |
Static Protected Member Functions inherited from Title | |
static | getSelectFields () |
Returns a list of fields that are to be selected for initializing Title objects or LinkCache entries. More... | |
Fake title class that triggers an error if any members are called.
Definition at line 26 of file FakeTitle.php.
FakeTitle::areRestrictionsCascading | ( | ) |
Returns cascading restrictions for the current article.
Reimplemented from Title.
Definition at line 87 of file FakeTitle.php.
References error().
FakeTitle::canExist | ( | ) |
Is this in a namespace that allows actual pages?
Reimplemented from Title.
Definition at line 128 of file FakeTitle.php.
References error().
FakeTitle::canTalk | ( | ) |
Could this title have a corresponding talk page?
Reimplemented from Title.
Definition at line 39 of file FakeTitle.php.
References error().
FakeTitle::canUseNoindex | ( | ) |
Whether the magic words INDEX and NOINDEX function for this page.
Reimplemented from Title.
Definition at line 140 of file FakeTitle.php.
References error().
FakeTitle::countRevisionsBetween | ( | $old, | |
$new | |||
) |
Definition at line 123 of file FakeTitle.php.
References error().
FakeTitle::deleteTitleProtection | ( | ) |
Remove any title protection due to page existing.
Reimplemented from Title.
Definition at line 71 of file FakeTitle.php.
References error().
FakeTitle::equals | ( | Title | $title | ) |
Compare with another title.
$title | Title |
Reimplemented from Title.
Definition at line 124 of file FakeTitle.php.
References error().
FakeTitle::error | ( | ) |
Definition at line 27 of file FakeTitle.php.
Referenced by areRestrictionsCascading(), canExist(), canTalk(), canUseNoindex(), countRevisionsBetween(), deleteTitleProtection(), equals(), escapeFullURL(), escapeLocalURL(), exists(), fixSpecialName(), getArticleID(), getBacklinkCache(), getBaseText(), getBrokenLinksFrom(), getCascadeProtectionSources(), getDBkey(), getDefaultNamespace(), getEarliestRevTime(), getEditURL(), getEscapedText(), getFirstRevision(), getFragment(), getFragmentForURL(), getFullText(), getFullURL(), getIndexTitle(), getInternalURL(), getInterwiki(), getLatestRevID(), getLength(), getLinksTo(), getLinkURL(), getLocalURL(), getNamespace(), getNamespaceKey(), getNextRevisionID(), getNotificationTimestamp(), getNsText(), getParentCategories(), getParentCategoryTree(), getPartialURL(), getPrefixedDBkey(), getPrefixedText(), getPrefixedURL(), getPreviousRevisionID(), getRedirectsHere(), getRestrictionExpiry(), getRestrictions(), getRestrictionTypes(), getSkinFromCssJsSubpage(), getSquidURLs(), getSubjectNsText(), getSubjectPage(), getSubpages(), getSubpageText(), getSubpageUrlForm(), getTalkNsText(), getTalkPage(), getTemplateLinksTo(), getText(), getTouched(), getUserCaseDBKey(), getUserPermissionsErrors(), hasFragment(), hasSubpages(), invalidateCache(), isAlwaysKnown(), isCascadeProtected(), isContentPage(), isConversionTable(), isCssJsSubpage(), isCssOrJsPage(), isCssSubpage(), isDeleted(), isDeletedQuick(), isExternal(), isJsSubpage(), isKnown(), isLocal(), isMovable(), isNamespaceProtected(), isNewPage(), isProtected(), isRedirect(), isSemiProtected(), isSingleRevRedirect(), isSpecial(), isSpecialPage(), isSubpage(), isTalkPage(), isTrans(), isValidMoveOperation(), isValidMoveTarget(), isValidRedirectTarget(), isWatchable(), loadRestrictions(), loadRestrictionsFromRows(), moveNoAuth(), moveSubpages(), moveTo(), pageCond(), purgeSquid(), quickUserCan(), resetArticleID(), setFragment(), touchLinks(), updateTitleProtection(), userCan(), userCanEditCssSubpage(), userCanEditJsSubpage(), userCanRead(), and userIsWatching().
FakeTitle::escapeFullURL | ( | $query = '' , |
|
$query2 = false |
|||
) |
Get an HTML-escaped version of the URL form, suitable for using in a link, including the server name and fragment.
Reimplemented from Title.
Definition at line 57 of file FakeTitle.php.
References error().
FakeTitle::escapeLocalURL | ( | $query = '' , |
|
$query2 = false |
|||
) |
Get an HTML-escaped version of the URL form, suitable for using in a link, without a server name or fragment.
$query | string |
$query2 | bool|string |
Reimplemented from Title.
Definition at line 56 of file FakeTitle.php.
References error().
FakeTitle::exists | ( | ) |
Check if page exists.
For historical reasons, this function simply checks for the existence of the title in the page table, and will thus return false for interwiki links, special pages and the like. If you want to know if a title can be meaningfully viewed, you should probably call the isKnown() method instead.
Reimplemented from Title.
Definition at line 125 of file FakeTitle.php.
References error().
FakeTitle::fixSpecialName | ( | ) |
FakeTitle::getArticleID | ( | $flags = 0 | ) |
Get the article ID for this Title from the link cache, adding it if necessary.
int | $flags | a bit field; may be Title::GAID_FOR_UPDATE to select for update |
Reimplemented from Title.
Definition at line 94 of file FakeTitle.php.
References error().
FakeTitle::getBacklinkCache | ( | ) |
Get a backlink cache object.
Reimplemented from Title.
Definition at line 139 of file FakeTitle.php.
References error().
FakeTitle::getBaseText | ( | ) |
Get the base page name without a namespace, i.e.
the part before the subpage name
Reimplemented from Title.
Definition at line 49 of file FakeTitle.php.
References error().
FakeTitle::getBrokenLinksFrom | ( | ) |
FakeTitle::getCascadeProtectionSources | ( | $getPages = true | ) |
Cascading protection: Get the source of any cascading restrictions on this page.
bool | $getPages | Whether or not to retrieve the actual pages that the restrictions have come from. |
Reimplemented from Title.
Definition at line 86 of file FakeTitle.php.
References error().
FakeTitle::getDBkey | ( | ) |
Get the main part with underscores.
Reimplemented from Title.
Definition at line 33 of file FakeTitle.php.
References error().
FakeTitle::getDefaultNamespace | ( | ) |
Get the default namespace index, for when there is no namespace.
Reimplemented from Title.
Definition at line 44 of file FakeTitle.php.
References error().
FakeTitle::getEarliestRevTime | ( | $flags = 0 | ) |
Get the oldest revision timestamp of this page.
int | $flags | Title::GAID_FOR_UPDATE |
Reimplemented from Title.
Definition at line 122 of file FakeTitle.php.
References error().
FakeTitle::getEditURL | ( | ) |
Get the edit URL for this Title.
Reimplemented from Title.
Definition at line 59 of file FakeTitle.php.
References error().
FakeTitle::getEscapedText | ( | ) |
Get the HTML-escaped displayable text form.
Used for the title field in tags.
Reimplemented from Title.
Definition at line 60 of file FakeTitle.php.
References error().
FakeTitle::getFirstRevision | ( | $flags = 0 | ) |
Get the first revision of the page.
int | $flags | Title::GAID_FOR_UPDATE |
Reimplemented from Title.
Definition at line 120 of file FakeTitle.php.
References error().
FakeTitle::getFragment | ( | ) |
Get the Title fragment (i.e. the bit after the #) in text form.
Use Title::hasFragment to check for a fragment
Reimplemented from Title.
Definition at line 41 of file FakeTitle.php.
References error().
FakeTitle::getFragmentForURL | ( | ) |
Get the fragment in URL form, including the "#" character if there is one.
Reimplemented from Title.
Definition at line 43 of file FakeTitle.php.
References error().
FakeTitle::getFullText | ( | ) |
Get the prefixed title with spaces, plus any fragment (part beginning with '#')
Reimplemented from Title.
Definition at line 48 of file FakeTitle.php.
References error().
FakeTitle::getFullURL | ( | $query = '' , |
|
$variant = false |
|||
) |
Definition at line 53 of file FakeTitle.php.
References error().
FakeTitle::getIndexTitle | ( | ) |
Get title for search index.
Reimplemented from Title.
Definition at line 45 of file FakeTitle.php.
References error().
FakeTitle::getInternalURL | ( | $query = '' , |
|
$query2 = false |
|||
) |
Get the URL form for an internal link.
This uses $wgInternalServer to qualify the path, or $wgServer if $wgInternalServer is not set. If the server variable used is protocol-relative, the URL will be expanded to http://
Reimplemented from Title.
Definition at line 58 of file FakeTitle.php.
References error().
FakeTitle::getInterwiki | ( | ) |
Get the interwiki prefix.
Use Title::isExternal to check if a interwiki is set
Reimplemented from Title.
Definition at line 40 of file FakeTitle.php.
References error().
FakeTitle::getLatestRevID | ( | $flags = 0 | ) |
What is the page_latest field for this page?
int | $flags | a bit field; may be Title::GAID_FOR_UPDATE to select for update |
Reimplemented from Title.
Definition at line 97 of file FakeTitle.php.
References error().
FakeTitle::getLength | ( | $flags = 0 | ) |
What is the length of this page? Uses link cache, adding it if necessary.
int | $flags | a bit field; may be Title::GAID_FOR_UPDATE to select for update |
Reimplemented from Title.
Definition at line 96 of file FakeTitle.php.
References error().
Get an array of Title objects linking to this Title Also stores the IDs in the link cache.
WARNING: do not use this function on arbitrary user-supplied titles! On heavily-used templates it will max out the memory.
array | $options | may be FOR UPDATE |
string | $table | table name |
string | $prefix | fields prefix |
Reimplemented from Title.
Definition at line 103 of file FakeTitle.php.
References error().
Definition at line 55 of file FakeTitle.php.
References error().
FakeTitle::getLocalURL | ( | $query = '' , |
|
$query2 = false |
|||
) |
Get a URL with no fragment or server name (relative URL) from a Title object.
If this page is generated with action=render, however, $wgServer is prepended to make an absolute URL.
string | array | $query | an optional query string, not used for interwiki links. Can be specified as an associative array as well, e.g., array( 'action' => 'edit' ) (keys and values will be URL-escaped). Some query patterns will trigger various shorturl path replacements. |
$query2 | Mixed: An optional secondary query array. This one MUST be an array. If a string is passed it will be interpreted as a deprecated variant argument and urlencoded into a variant= argument. This second query argument will be added to the $query The second parameter is deprecated since 1.19. Pass it as a key,value pair in the first parameter array instead. |
Reimplemented from Title.
Definition at line 54 of file FakeTitle.php.
References error().
FakeTitle::getNamespace | ( | ) |
Get the namespace index, i.e.
one of the NS_xxxx constants.
Reimplemented from Title.
Definition at line 34 of file FakeTitle.php.
References error().
FakeTitle::getNamespaceKey | ( | $prepend = 'nstab-' | ) |
Generate strings used for xml 'id' names in monobook tabs.
string | $prepend | defaults to 'nstab-' |
Reimplemented from Title.
Definition at line 132 of file FakeTitle.php.
References error().
FakeTitle::getNextRevisionID | ( | $revId, | |
$flags = 0 |
|||
) |
Get the revision ID of the next revision.
int | $revId | Revision ID. Get the revision that was after this one. |
int | $flags | Title::GAID_FOR_UPDATE |
Reimplemented from Title.
Definition at line 119 of file FakeTitle.php.
References error().
FakeTitle::getNotificationTimestamp | ( | $user = null | ) |
Get the timestamp when this page was updated since the user last saw it.
$user | User |
Reimplemented from Title.
Definition at line 131 of file FakeTitle.php.
References error().
FakeTitle::getNsText | ( | ) |
Get the namespace text.
Reimplemented from Title.
Definition at line 35 of file FakeTitle.php.
References error().
FakeTitle::getParentCategories | ( | ) |
Get categories to which this Title belongs and return an array of categories' names.
Reimplemented from Title.
Definition at line 115 of file FakeTitle.php.
References error().
FakeTitle::getParentCategoryTree | ( | $children = array() | ) |
Get a tree of parent categories.
array | $children | with the children in the keys, to check for circular refs |
Reimplemented from Title.
Definition at line 116 of file FakeTitle.php.
References error().
FakeTitle::getPartialURL | ( | ) |
Get the URL-encoded form of the main part.
Reimplemented from Title.
Definition at line 32 of file FakeTitle.php.
References error().
FakeTitle::getPrefixedDBkey | ( | ) |
Get the prefixed database key form.
Reimplemented from Title.
Definition at line 46 of file FakeTitle.php.
References error().
FakeTitle::getPrefixedText | ( | ) |
Get the prefixed title with spaces.
This is the form usually used for display
Reimplemented from Title.
Definition at line 47 of file FakeTitle.php.
References error().
FakeTitle::getPrefixedURL | ( | ) |
Get a URL-encoded title (not an actual URL) including interwiki.
Reimplemented from Title.
Definition at line 52 of file FakeTitle.php.
References error().
FakeTitle::getPreviousRevisionID | ( | $revId, | |
$flags = 0 |
|||
) |
Get the revision ID of the previous revision.
int | $revId | Revision ID. Get the revision that was before this one. |
int | $flags | Title::GAID_FOR_UPDATE |
Reimplemented from Title.
Definition at line 118 of file FakeTitle.php.
References error().
FakeTitle::getRedirectsHere | ( | $ns = null | ) |
FakeTitle::getRestrictionExpiry | ( | $action | ) |
Get the expiry time for the restriction against a given action.
$action |
Reimplemented from Title.
Definition at line 91 of file FakeTitle.php.
References error().
FakeTitle::getRestrictions | ( | $action | ) |
Accessor/initialisation for mRestrictions.
string | $action | action that permission needs to be checked for |
Reimplemented from Title.
Definition at line 90 of file FakeTitle.php.
References error().
FakeTitle::getRestrictionTypes | ( | ) |
Returns restriction types for the current Title.
Reimplemented from Title.
Definition at line 141 of file FakeTitle.php.
References error().
FakeTitle::getSkinFromCssJsSubpage | ( | ) |
Trim down a .css or .js subpage title to get the corresponding skin name.
Reimplemented from Title.
Definition at line 80 of file FakeTitle.php.
References error().
FakeTitle::getSquidURLs | ( | ) |
Get a list of URLs to purge from the Squid cache when this page changes.
Reimplemented from Title.
Definition at line 106 of file FakeTitle.php.
References error().
FakeTitle::getSubjectNsText | ( | ) |
Get the namespace text of the subject (rather than talk) page.
Reimplemented from Title.
Definition at line 37 of file FakeTitle.php.
References error().
FakeTitle::getSubjectPage | ( | ) |
Get a title object associated with the subject page of this talk page.
Reimplemented from Title.
Definition at line 102 of file FakeTitle.php.
References error().
FakeTitle::getSubpages | ( | $limit = -1 | ) |
Get all subpages of this page.
int | $limit | maximum number of subpages to fetch; -1 for no limit |
Reimplemented from Title.
Definition at line 77 of file FakeTitle.php.
References error().
FakeTitle::getSubpageText | ( | ) |
Get the lowest-level subpage name, i.e.
the rightmost part after any slashes
Reimplemented from Title.
Definition at line 50 of file FakeTitle.php.
References error().
FakeTitle::getSubpageUrlForm | ( | ) |
Get a URL-encoded form of the subpage text.
Reimplemented from Title.
Definition at line 51 of file FakeTitle.php.
References error().
FakeTitle::getTalkNsText | ( | ) |
Get the namespace text of the talk page.
Reimplemented from Title.
Definition at line 38 of file FakeTitle.php.
References error().
FakeTitle::getTalkPage | ( | ) |
FakeTitle::getTemplateLinksTo | ( | $options = array() | ) |
Get an array of Title objects using this Title as a template Also stores the IDs in the link cache.
WARNING: do not use this function on arbitrary user-supplied titles! On heavily-used templates it will max out the memory.
array | $options | may be FOR UPDATE |
Reimplemented from Title.
Definition at line 104 of file FakeTitle.php.
References error().
FakeTitle::getText | ( | ) |
Get the text form (spaces not underscores) of the main part.
Reimplemented from Title.
Definition at line 31 of file FakeTitle.php.
References error().
FakeTitle::getTouched | ( | $db = null | ) |
Get the last touched timestamp.
$db | DatabaseBase: optional db |
Reimplemented from Title.
Definition at line 130 of file FakeTitle.php.
References error().
FakeTitle::getUserCaseDBKey | ( | ) |
Get the DB key with the initial letter case as specified by the user.
Reimplemented from Title.
Definition at line 36 of file FakeTitle.php.
References error().
FakeTitle::getUserPermissionsErrors | ( | $action, | |
$user, | |||
$doExpensiveQueries = true , |
|||
$ignoreErrors = array() |
|||
) |
Can $user perform $action on this page?
string | $action | action that permission needs to be checked for |
$user | User to check | |
bool | $doExpensiveQueries | Set this to false to avoid doing unnecessary queries by skipping checks for cascading protections and user blocks. |
array | $ignoreErrors | of Strings Set this to a list of message keys whose corresponding errors may be ignored. |
Reimplemented from Title.
Definition at line 69 of file FakeTitle.php.
References error().
FakeTitle::hasFragment | ( | ) |
Check if a Title fragment is set.
Reimplemented from Title.
Definition at line 42 of file FakeTitle.php.
References error().
FakeTitle::hasSubpages | ( | ) |
Does this have subpages? (Warning, usually requires an extra DB query.)
Reimplemented from Title.
Definition at line 76 of file FakeTitle.php.
References error().
FakeTitle::invalidateCache | ( | ) |
Updates page_touched for this page; called from LinksUpdate.php.
Reimplemented from Title.
Definition at line 99 of file FakeTitle.php.
References error().
FakeTitle::isAlwaysKnown | ( | ) |
Should links to this title be shown as potentially viewable (i.e.
as "bluelinks"), even if there's no record by this title in the page table?
This function is semi-deprecated for public use, as well as somewhat misleadingly named. You probably just want to call isKnown(), which calls this function internally.
(ISSUE: Most of these checks are cheap, but the file existence check can potentially be quite expensive. Including it here fixes a lot of existing code, but we might want to add an optional parameter to skip it and any other expensive checks.)
Reimplemented from Title.
Definition at line 126 of file FakeTitle.php.
References error().
FakeTitle::isCascadeProtected | ( | ) |
Cascading protection: Return true if cascading restrictions apply to this page, false if not.
Reimplemented from Title.
Definition at line 85 of file FakeTitle.php.
References error().
FakeTitle::isContentPage | ( | ) |
Is this Title in a namespace which contains content? In other words, is this a content page, for the purposes of calculating statistics, etc?
Reimplemented from Title.
Definition at line 136 of file FakeTitle.php.
References error().
FakeTitle::isConversionTable | ( | ) |
Is this a conversion table for the LanguageConverter?
Reimplemented from Title.
Definition at line 64 of file FakeTitle.php.
References error().
FakeTitle::isCssJsSubpage | ( | ) |
Is this a .css or .js subpage of a user page?
Reimplemented from Title.
Definition at line 78 of file FakeTitle.php.
References error().
FakeTitle::isCssOrJsPage | ( | ) |
Could this page contain custom CSS or JavaScript for the global UI.
This is generally true for pages in the MediaWiki namespace having CONTENT_MODEL_CSS or CONTENT_MODEL_JAVASCRIPT.
This method does not return true for per-user JS/CSS. Use isCssJsSubpage() for that!
Note that this method should not return true for pages that contain and show "inactive" CSS or JS.
Reimplemented from Title.
Definition at line 79 of file FakeTitle.php.
References error().
FakeTitle::isCssSubpage | ( | ) |
Is this a .css subpage of a user page?
Reimplemented from Title.
Definition at line 81 of file FakeTitle.php.
References error().
FakeTitle::isDeleted | ( | ) |
Is there a version of this page in the deletion archive?
Reimplemented from Title.
Definition at line 92 of file FakeTitle.php.
References error().
FakeTitle::isDeletedQuick | ( | ) |
Is there a version of this page in the deletion archive?
Reimplemented from Title.
Definition at line 93 of file FakeTitle.php.
References error().
FakeTitle::isExternal | ( | ) |
Is this Title interwiki?
Reimplemented from Title.
Definition at line 61 of file FakeTitle.php.
References error().
FakeTitle::isJsSubpage | ( | ) |
Is this a .js subpage of a user page?
Reimplemented from Title.
Definition at line 82 of file FakeTitle.php.
References error().
FakeTitle::isKnown | ( | ) |
Does this title refer to a page that can (or might) be meaningfully viewed? In particular, this function may be used to determine if links to the title should be rendered as "bluelinks" (as opposed to "redlinks" to non-existent pages).
Adding something else to this function will cause inconsistency since LinkHolderArray calls isAlwaysKnown() and does its own page existence check.
Reimplemented from Title.
Definition at line 127 of file FakeTitle.php.
References error().
FakeTitle::isLocal | ( | ) |
Determine whether the object refers to a page within this project.
Reimplemented from Title.
Definition at line 29 of file FakeTitle.php.
References error().
FakeTitle::isMovable | ( | ) |
Would anybody with sufficient privileges be able to move this page? Some pages just aren't movable.
Reimplemented from Title.
Definition at line 72 of file FakeTitle.php.
References error().
FakeTitle::isNamespaceProtected | ( | User | $user | ) |
Determines if $user is unable to edit this page because it has been protected by $wgNamespaceProtection.
$user | User object to check permissions |
Reimplemented from Title.
Definition at line 67 of file FakeTitle.php.
References error().
FakeTitle::isNewPage | ( | ) |
Check if this is a new page.
Reimplemented from Title.
Definition at line 121 of file FakeTitle.php.
References error().
FakeTitle::isProtected | ( | $action = '' | ) |
Does the title correspond to a protected article?
string | $action | the action the page is protected from, by default checks all actions. |
Reimplemented from Title.
Definition at line 63 of file FakeTitle.php.
References error().
FakeTitle::isRedirect | ( | $flags = 0 | ) |
Is this an article that is a redirect page? Uses link cache, adding it if necessary.
int | $flags | a bit field; may be Title::GAID_FOR_UPDATE to select for update |
Reimplemented from Title.
Definition at line 95 of file FakeTitle.php.
References error().
FakeTitle::isSemiProtected | ( | $action = 'edit' | ) |
Is this page "semi-protected" - the only protection levels are listed in $wgSemiprotectedRestrictionLevels?
string | $action | Action to check (default: edit) |
Reimplemented from Title.
Definition at line 62 of file FakeTitle.php.
References error().
FakeTitle::isSingleRevRedirect | ( | ) |
Checks if this page is just a one-rev redirect.
Adds lock, so don't use just for light purposes.
Reimplemented from Title.
Definition at line 112 of file FakeTitle.php.
References error().
FakeTitle::isSpecial | ( | $name | ) |
Returns true if this title resolves to the named special page.
string | $name | The special page name |
Reimplemented from Title.
Definition at line 134 of file FakeTitle.php.
References error().
FakeTitle::isSpecialPage | ( | ) |
Returns true if this is a special page.
Reimplemented from Title.
Definition at line 133 of file FakeTitle.php.
References error().
FakeTitle::isSubpage | ( | ) |
Is this a subpage?
Reimplemented from Title.
Definition at line 75 of file FakeTitle.php.
References error().
FakeTitle::isTalkPage | ( | ) |
Is this a talk page of some sort?
Reimplemented from Title.
Definition at line 74 of file FakeTitle.php.
References error().
FakeTitle::isTrans | ( | ) |
Determine whether the object refers to a page within this project and is transcludable.
Reimplemented from Title.
Definition at line 30 of file FakeTitle.php.
References error().
FakeTitle::isValidMoveOperation | ( | & | $nt, |
$auth = true , |
|||
$reason = '' |
|||
) |
Check whether a given move operation would be valid.
Returns true if ok, or a getUserPermissionsErrors()-like array otherwise
$nt | Title the new title | |
bool | $auth | indicates whether $wgUser's permissions should be checked |
string | $reason | is the log summary of the move, used for spam checking |
Reimplemented from Title.
Definition at line 109 of file FakeTitle.php.
References error().
FakeTitle::isValidMoveTarget | ( | $nt | ) |
FakeTitle::isValidRedirectTarget | ( | ) |
Check if this Title is a valid redirect target.
Reimplemented from Title.
Definition at line 138 of file FakeTitle.php.
References error().
FakeTitle::isWatchable | ( | ) |
Can this title be added to a user's watchlist?
Reimplemented from Title.
Definition at line 114 of file FakeTitle.php.
References error().
FakeTitle::loadRestrictions | ( | $oldFashionedRestrictions = null | ) |
Load restrictions from the page_restrictions table.
string | $oldFashionedRestrictions | comma-separated list of page restrictions from page table (pre 1.10) |
Reimplemented from Title.
Definition at line 89 of file FakeTitle.php.
References error().
FakeTitle::loadRestrictionsFromRows | ( | $rows, | |
$oldFashionedRestrictions = null |
|||
) |
Compiles list of active page restrictions from both page table (pre 1.10) and page_restrictions table for this existing page.
Public for usage by LiquidThreads.
array | $rows | of db result objects |
string | $oldFashionedRestrictions | comma-separated list of page restrictions from page table (pre 1.10) |
Reimplemented from Title.
Definition at line 88 of file FakeTitle.php.
References error().
FakeTitle::moveNoAuth | ( | & | $nt | ) |
Move this page without authentication.
Reimplemented from Title.
Definition at line 108 of file FakeTitle.php.
References error().
Move this page's subpages to be subpages of $nt.
$nt | Title Move target | |
bool | $auth | Whether $wgUser's permissions should be checked |
string | $reason | The reason for the move |
bool | $createRedirect | Whether to create redirects from the old subpages to the new ones Ignored if the user doesn't have the 'suppressredirect' right |
Reimplemented from Title.
Definition at line 111 of file FakeTitle.php.
References error().
Move a title to a new location.
$nt | Title the new title | |
bool | $auth | indicates whether $wgUser's permissions should be checked |
string | $reason | the reason for the move |
bool | $createRedirect | Whether to create a redirect from the old title to the new title. Ignored if the user doesn't have the suppressredirect right. |
Reimplemented from Title.
Definition at line 110 of file FakeTitle.php.
References error().
FakeTitle::pageCond | ( | ) |
Get an associative array for selecting this title from the "page" table.
Reimplemented from Title.
Definition at line 117 of file FakeTitle.php.
References error().
FakeTitle::purgeSquid | ( | ) |
Purge all applicable Squid URLs.
Reimplemented from Title.
Definition at line 107 of file FakeTitle.php.
References error().
FakeTitle::quickUserCan | ( | $action, | |
$user = null |
|||
) |
Can $user perform $action on this page? This skips potentially expensive cascading permission checks as well as avoids expensive error formatting.
Suitable for use for nonessential UI controls in common cases, but not for functional access control.
May provide false positives, but should never provide a false negative.
string | $action | action that permission needs to be checked for |
$user | User to check (since 1.19); $wgUser will be used if not provided. |
Reimplemented from Title.
Definition at line 66 of file FakeTitle.php.
References error().
FakeTitle::resetArticleID | ( | $newid | ) |
This clears some fields in this object, and clears any associated keys in the "bad links" section of the link cache.
int | $newid | the new Article ID |
Reimplemented from Title.
Definition at line 98 of file FakeTitle.php.
References error().
FakeTitle::setFragment | ( | $fragment | ) |
Set the fragment for this title.
Removes the first character from the specified fragment before setting, so it assumes you're passing it with an initial "#".
Deprecated for public use, use Title::makeTitle() with fragment parameter. Still in active use privately.
string | $fragment | text |
Reimplemented from Title.
Definition at line 101 of file FakeTitle.php.
References error().
FakeTitle::touchLinks | ( | ) |
Update page_touched timestamps and send squid purge messages for pages linking to this title.
May be sent to the job queue depending on the number of links. Typically called on create and delete.
Reimplemented from Title.
Definition at line 129 of file FakeTitle.php.
References error().
FakeTitle::updateTitleProtection | ( | $create_perm, | |
$reason, | |||
$expiry | |||
) |
Update the title protection status.
$create_perm | String Permission required for creation | |
string | $reason | Reason for protection |
string | $expiry | Expiry timestamp |
Reimplemented from Title.
Definition at line 70 of file FakeTitle.php.
References error().
FakeTitle::userCan | ( | $action, | |
$user = null , |
|||
$doExpensiveQueries = true |
|||
) |
Can $user perform $action on this page?
string | $action | action that permission needs to be checked for |
$user | User to check (since 1.19); $wgUser will be used if not provided. | |
bool | $doExpensiveQueries | Set this to false to avoid doing unnecessary queries. |
Reimplemented from Title.
Definition at line 68 of file FakeTitle.php.
References error().
FakeTitle::userCanEditCssSubpage | ( | ) |
Definition at line 83 of file FakeTitle.php.
References error().
FakeTitle::userCanEditJsSubpage | ( | ) |
Definition at line 84 of file FakeTitle.php.
References error().
FakeTitle::userCanRead | ( | ) |
Can $wgUser read this page?
Reimplemented from Title.
Definition at line 73 of file FakeTitle.php.
References error().
FakeTitle::userIsWatching | ( | ) |
Is $wgUser watching this page?
Reimplemented from Title.
Definition at line 65 of file FakeTitle.php.
References error().