Inherited by FakeTitle.
Public Member Functions | |
isLocal () | |
Determine whether the object refers to a page within this project. | |
isTrans () | |
Determine whether the object refers to a page within this project and is transcludable. | |
getText () | |
Simple accessors. | |
getPartialURL () | |
Get the URL-encoded form of the main part. | |
getDBkey () | |
Get the main part with underscores. | |
getNamespace () | |
Get the namespace index, i.e. one of the NS_xxxx constants. | |
getNsText () | |
Get the namespace text. | |
getUserCaseDBKey () | |
Get the DB key with the initial letter case as specified by the user. | |
getSubjectNsText () | |
Get the namespace text of the subject (rather than talk) page. | |
getTalkNsText () | |
Get the namespace text of the talk page. | |
canTalk () | |
Could this title have a corresponding talk page? | |
getInterwiki () | |
Get the interwiki prefix (or null string). | |
getFragment () | |
Get the Title fragment (i.e. the bit after the #) in text form. | |
getFragmentForURL () | |
Get the fragment in URL form, including the "#" character if there is one. | |
getDefaultNamespace () | |
Get the default namespace index, for when there is no namespace. | |
getIndexTitle () | |
Get title for search index. | |
getPrefixedDBkey () | |
Get the prefixed database key form. | |
getPrefixedText () | |
Get the prefixed title with spaces. | |
getFullText () | |
Get the prefixed title with spaces, plus any fragment (part beginning with '#'). | |
getBaseText () | |
Get the base name, i.e. | |
getSubpageText () | |
Get the lowest-level subpage name, i.e. | |
getSubpageUrlForm () | |
Get a URL-encoded form of the subpage text. | |
getPrefixedURL () | |
Get a URL-encoded title (not an actual URL) including interwiki. | |
getFullURL ($query= '', $variant=false) | |
Get a real URL referring to this title, with interwiki link and fragment. | |
getLocalURL ($query= '', $variant=false) | |
Get a URL with no fragment or server name. | |
getLinkUrl ($query=array(), $variant=false) | |
Get a URL that's the simplest URL that will be valid to link, locally, to the current Title. | |
escapeLocalURL ($query= '') | |
Get an HTML-escaped version of the URL form, suitable for using in a link, without a server name or fragment. | |
escapeFullURL ($query= '') | |
Get an HTML-escaped version of the URL form, suitable for using in a link, including the server name and fragment. | |
getInternalURL ($query= '', $variant=false) | |
Get the URL form for an internal link. | |
getEditURL () | |
Get the edit URL for this Title. | |
getEscapedText () | |
Get the HTML-escaped displayable text form. | |
isExternal () | |
Is this Title interwiki? | |
isSemiProtected ($action= 'edit') | |
Is this page "semi-protected" - the *only* protection is autoconfirm? | |
isProtected ($action= '') | |
Does the title correspond to a protected article? | |
userIsWatching () | |
Is $wgUser watching this page? | |
quickUserCan ($action) | |
Can $wgUser perform $action on this page? This skips potentially expensive cascading permission checks. | |
isNamespaceProtected () | |
Determines if $wgUser is unable to edit this page because it has been protected by $wgNamespaceProtection. | |
userCan ($action, $doExpensiveQueries=true) | |
Can $wgUser perform $action on this page? | |
getUserPermissionsErrors ($action, $user, $doExpensiveQueries=true, $ignoreErrors=array()) | |
Can $user perform $action on this page? | |
updateTitleProtection ($create_perm, $reason, $expiry) | |
Update the title protection status. | |
deleteTitleProtection () | |
Remove any title protection due to page existing. | |
userCanEdit ($doExpensiveQueries=true) | |
Can $wgUser edit this page? | |
userCanCreate ($doExpensiveQueries=true) | |
Can $wgUser create this page? | |
userCanMove ($doExpensiveQueries=true) | |
Can $wgUser move this page? | |
isMovable () | |
Would anybody with sufficient privileges be able to move this page? Some pages just aren't movable. | |
userCanRead () | |
Can $wgUser read this page? | |
isTalkPage () | |
Is this a talk page of some sort? | |
isSubpage () | |
Is this a subpage? | |
hasSubpages () | |
Does this have subpages? (Warning, usually requires an extra DB query. | |
getSubpages ($limit=-1) | |
Get all subpages of this page. | |
isCssOrJsPage () | |
Could this page contain custom CSS or JavaScript, based on the title? | |
isCssJsSubpage () | |
Is this a .css or .js subpage of a user page? | |
isValidCssJsSubpage () | |
Is this a *valid* .css or .js subpage of a user page? Check that the corresponding skin exists. | |
getSkinFromCssJsSubpage () | |
Trim down a .css or .js subpage title to get the corresponding skin name. | |
isCssSubpage () | |
Is this a .css subpage of a user page? | |
isJsSubpage () | |
Is this a .js subpage of a user page? | |
userCanEditCssJsSubpage () | |
Protect css/js subpages of user pages: can $wgUser edit this page? | |
isCascadeProtected () | |
Cascading protection: Return true if cascading restrictions apply to this page, false if not. | |
getCascadeProtectionSources ($get_pages=true) | |
Cascading protection: Get the source of any cascading restrictions on this page. | |
areRestrictionsCascading () | |
loadRestrictions ($oldFashionedRestrictions=NULL) | |
Load restrictions from the page_restrictions table. | |
getRestrictions ($action) | |
Accessor/initialisation for mRestrictions. | |
getRestrictionExpiry ($action) | |
Get the expiry time for the restriction against a given action. | |
isDeleted () | |
Is there a version of this page in the deletion archive? | |
isDeletedQuick () | |
Is there a version of this page in the deletion archive? | |
getArticleID ($flags=0) | |
Get the article ID for this Title from the link cache, adding it if necessary. | |
isRedirect ($flags=0) | |
Is this an article that is a redirect page? Uses link cache, adding it if necessary. | |
getLength ($flags=0) | |
What is the length of this page? Uses link cache, adding it if necessary. | |
getLatestRevID ($flags=0) | |
What is the page_latest field for this page? | |
resetArticleID ($newid) | |
This clears some fields in this object, and clears any associated keys in the "bad links" section of the link cache. | |
invalidateCache () | |
Updates page_touched for this page; called from LinksUpdate.php. | |
prefix ($name) | |
Prefix some arbitrary text with the namespace or interwiki prefix of this object. | |
setFragment ($fragment) | |
Set the fragment for this title. | |
getTalkPage () | |
Get a Title object associated with the talk page of this article. | |
getSubjectPage () | |
Get a title object associated with the subject page of this talk page. | |
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. | |
getTemplateLinksTo ($options=array()) | |
Get an array of Title objects using this Title as a template Also stores the IDs in the link cache. | |
getBrokenLinksFrom () | |
Get an array of Title objects referring to non-existent articles linked from this page. | |
getSquidURLs () | |
Get a list of URLs to purge from the Squid cache when this page changes. | |
purgeSquid () | |
Purge all applicable Squid URLs. | |
moveNoAuth (&$nt) | |
Move this page without authentication. | |
isValidMoveOperation (&$nt, $auth=true, $reason= '') | |
Check whether a given move operation would be valid. | |
moveTo (&$nt, $auth=true, $reason= '', $createRedirect=true) | |
Move a title to a new location. | |
moveSubpages ($nt, $auth=true, $reason= '', $createRedirect=true) | |
Move this page's subpages to be subpages of $nt. | |
isSingleRevRedirect () | |
Checks if this page is just a one-rev redirect. | |
isValidMoveTarget ($nt) | |
Checks if $this can be moved to a given Title
| |
isWatchable () | |
Can this title be added to a user's watchlist? | |
getParentCategories () | |
Get categories to which this Title belongs and return an array of categories' names. | |
getParentCategoryTree ($children=array()) | |
Get a tree of parent categories. | |
pageCond () | |
Get an associative array for selecting this title from the "page" table. | |
getPreviousRevisionID ($revId, $flags=0) | |
Get the revision ID of the previous revision. | |
getNextRevisionID ($revId, $flags=0) | |
Get the revision ID of the next revision. | |
getFirstRevision ($flags=0) | |
Get the first revision of the page. | |
isNewPage () | |
Check if this is a new page. | |
getEarliestRevTime () | |
Get the oldest revision timestamp of this page. | |
countRevisionsBetween ($old, $new) | |
Get the number of revisions between the given revision IDs. | |
equals (Title $title) | |
Compare with another title. | |
__toString () | |
Return a string representation of this title. | |
exists () | |
Check if page exists. | |
isAlwaysKnown () | |
Should links to this title be shown as potentially viewable (i.e. | |
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). | |
canExist () | |
Is this in a namespace that allows actual pages? | |
touchLinks () | |
Update page_touched timestamps and send squid purge messages for pages linking to this title. | |
getTouched ($db=NULL) | |
Get the last touched timestamp. | |
getNotificationTimestamp ($user=NULL) | |
Get the timestamp when this page was updated since the user last saw it. | |
trackbackURL () | |
Get the trackback URL for this page. | |
trackbackRDF () | |
Get the trackback RDF for this page. | |
getNamespaceKey () | |
Generate strings used for xml 'id' names in monobook tabs. | |
isSpecial ($name) | |
Returns true if this title resolves to the named special page. | |
fixSpecialName () | |
If the Title refers to a special page alias which is not the local default,. | |
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? | |
getRedirectsHere ($ns=null) | |
Get all extant redirects to this Title. | |
isValidRedirectTarget () | |
Check if this Title is a valid redirect target. | |
getBacklinkCache () | |
Get a backlink cache object. | |
Static Public Member Functions | |
static | newFromDBkey ($key) |
Create a new Title from a prefixed DB key. | |
static | newFromText ($text, $defaultNamespace=NS_MAIN) |
Create a new Title from text, such as what one would find in a link. | |
static | newFromURL ($url) |
Create a new Title from URL-encoded text. | |
static | newFromID ($id, $flags=0) |
Create a new Title from an article ID. | |
static | newFromIDs ($ids) |
Make an array of titles from an array of IDs. | |
static | newFromRow ($row) |
Make a Title object from a DB row. | |
static & | makeTitle ($ns, $title, $fragment= '') |
Create a new Title from a namespace index and a DB key. | |
static | makeTitleSafe ($ns, $title, $fragment= '') |
Create a new Title from a namespace index and a DB key. | |
static | newMainPage () |
Create a new Title for the Main Page. | |
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. | |
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. | |
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). | |
static | nameOf ($id) |
Get the prefixed DB key associated with an ID. | |
static | legalChars () |
Get a regex character class describing the legal characters in a link. | |
static | indexTitle ($ns, $title) |
Get a string representation of a title suitable for including in a search index. | |
static | makeName ($ns, $title, $fragment= '') |
getInterwikiLink ($key) | |
Returns the URL associated with an interwiki prefix. | |
static | escapeFragmentForURL ($fragment) |
Escape a text fragment, say from a link, for a URL. | |
static | purgeExpiredRestrictions () |
Purge expired restrictions from the page_restrictions table. | |
static | compare ($a, $b) |
Callback for usort() to do title sorts by (namespace, title). | |
Public Attributes | |
const | CACHE_MAX = 1000 |
Title::newFromText maintains a cache to avoid expensive re-normalization of commonly used titles. | |
Private member variables | |
Please use the accessor functions instead.
| |
$mTextform = '' | |
Text form (spaces not underscores) of the main part. | |
$mUrlform = '' | |
URL-encoded form of the main part. | |
$mDbkeyform = '' | |
Main part with underscores. | |
$mUserCaseDBKey | |
DB key with the initial letter in the case specified by the user. | |
$mNamespace = NS_MAIN | |
Namespace index, i.e. one of the NS_xxxx constants. | |
$mInterwiki = '' | |
Interwiki prefix (or null string). | |
$mFragment | |
Title fragment (i.e. the bit after the #). | |
$mArticleID = -1 | |
Article ID, fetched from the link cache on demand. | |
$mLatestID = false | |
ID of most recent revision. | |
$mRestrictions = array() | |
Array of groups allowed to edit this article. | |
$mOldRestrictions = false | |
Text form (spaces not underscores) of the main part. | |
$mCascadeRestriction | |
Cascade restrictions on this page to included templates and images? | |
$mRestrictionsExpiry = array() | |
When do the restrictions on this page expire? | |
$mHasCascadingRestrictions | |
Are cascading restrictions in effect on this page? | |
$mCascadeSources | |
Where are the cascading restrictions coming from on this page? | |
$mRestrictionsLoaded = false | |
Boolean for initialisation on demand. | |
$mPrefixedText | |
Text form including namespace/interwiki, initialised on demand. | |
$mDefaultNamespace = NS_MAIN | |
Namespace index when there is no namespace. | |
$mWatched = null | |
Is $wgUser watching this page? null if unfilled, accessed through userIsWatching(). | |
$mLength = -1 | |
The page length, 0 for special pages. | |
$mRedirect = null | |
Is the article at this title a redirect? | |
$mNotificationTimestamp = array() | |
Associative array of user ID -> timestamp/false. | |
$mBacklinkCache = null | |
Cache of links to this title. | |
Static Protected Member Functions | |
static | newFromRedirectInternal ($text) |
Really extract the redirect destination Do not call this function directly, use one of the newFromRedirect* functions above. | |
Private Member Functions | |
__construct () | |
Constructor. | |
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. | |
getTitleProtection () | |
Is this title subject to title protection? | |
loadRestrictionsFromRow ($res, $oldFashionedRestrictions=NULL) | |
Loads a string into mRestrictions array. | |
secureAndSplit () | |
Secure and split - main initialisation function for this object. | |
moveOverExistingRedirect (&$nt, $reason= '', $createRedirect=true) | |
Move page to a title which is at present a redirect to the source page. | |
moveToNewTitle (&$nt, $reason= '', $createRedirect=true) | |
Move page to non-existing title. | |
Static Private Attributes | |
Static cache variables | |
static | $titleCache = array() |
static | $interwikiCache = array() |
Optionally may contain an interwiki designation or namespace.
Definition at line 25 of file Title.php.
Title::__toString | ( | ) |
Return a string representation of this title.
Definition at line 3357 of file Title.php.
References getPrefixedText().
Title::areRestrictionsCascading | ( | ) |
Title::canExist | ( | ) |
Title::canTalk | ( | ) |
Could this title have a corresponding talk page?
Definition at line 600 of file Title.php.
References MWNamespace::canTalk().
static Title::compare | ( | $ | a, | |
$ | b | |||
) | [static] |
Callback for usort() to do title sorts by (namespace, title).
Definition at line 3344 of file Title.php.
Referenced by ApiQueryInfo::execute().
Title::countRevisionsBetween | ( | $ | old, | |
$ | new | |||
) |
Title::deleteTitleProtection | ( | ) |
Remove any title protection due to page existing.
Definition at line 1460 of file Title.php.
References $dbw, getDBkey(), getNamespace(), and wfGetDB().
Title::equals | ( | Title $ | title | ) |
Compare with another title.
<b> | Title : $title |
Definition at line 3334 of file Title.php.
References getDBkey(), getInterwiki(), and getNamespace().
Referenced by Parser::getTemplateDom(), and isValidMoveOperation().
static Title::escapeFragmentForURL | ( | $ | fragment | ) | [static] |
Escape a text fragment, say from a link, for a URL.
Definition at line 518 of file Title.php.
References $wgEnforceHtmlIds, and Sanitizer::escapeId().
Referenced by getFragmentForURL().
Title::escapeFullURL | ( | $ | query = '' |
) |
Get an HTML-escaped version of the URL form, suitable for using in a link, including the server name and fragment.
$query | String : : an optional query string |
Reimplemented in FakeTitle.
Definition at line 904 of file Title.php.
References getFullURL().
Title::escapeLocalURL | ( | $ | query = '' |
) |
Get an HTML-escaped version of the URL form, suitable for using in a link, without a server name or fragment.
$query | String : : an optional query string |
Reimplemented in FakeTitle.
Definition at line 893 of file Title.php.
References getLocalURL().
Title::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 in FakeTitle.
Definition at line 3370 of file Title.php.
Referenced by getEarliestRevTime(), isAlwaysKnown(), isKnown(), isSemiProtected(), isValidMoveOperation(), and loadRestrictions().
Title::fixSpecialName | ( | ) |
If the Title refers to a special page alias which is not the local default,.
Definition at line 3591 of file Title.php.
References SpecialPage::getLocalNameFor(), getNamespace(), makeTitle(), and SpecialPage::resolveAlias().
Title::getArticleID | ( | $ | flags = 0 |
) |
Get the article ID for this Title from the link cache, adding it if necessary.
$flags | Integer : : a bit field; may be GAID_FOR_UPDATE to select for update |
Reimplemented in FakeTitle.
Definition at line 2029 of file Title.php.
References $flags, getNamespace(), and LinkCache::singleton().
Referenced by getLength(), isRedirect(), isValidMoveOperation(), moveOverExistingRedirect(), moveTo(), moveToNewTitle(), and Parser::statelessFetchTemplate().
Title::getBaseText | ( | ) |
Get the base name, i.e.
the leftmost parts before the /
Definition at line 682 of file Title.php.
References getText(), and MWNamespace::hasSubpages().
Title::getBrokenLinksFrom | ( | ) |
Get an array of Title objects referring to non-existent articles linked from this page.
Reimplemented in FakeTitle.
Definition at line 2474 of file Title.php.
References $dbr, $res, $row, makeTitle(), and wfGetDB().
Title::getCascadeProtectionSources | ( | $ | get_pages = true |
) |
Cascading protection: Get the source of any cascading restrictions on this page.
$get_pages | Boolean : : Whether or not to retrieve the actual pages that the restrictions have come from. |
Definition at line 1734 of file Title.php.
References $action, $dbr, $res, $row, $wgRestrictionTypes, Block::decodeExpiry(), getDBkey(), getNamespace(), makeTitle(), purgeExpiredRestrictions(), wfGetDB(), wfProfileIn(), wfProfileOut(), and wfTimestampNow().
Referenced by getUserPermissionsErrorsInternal(), and isCascadeProtected().
Title::getDBkey | ( | ) |
Get the main part with underscores.
Reimplemented in FakeTitle.
Definition at line 547 of file Title.php.
Referenced by TitleDependency::__construct(), CoreLinkFunctions::categoryLinkHook(), deleteTitleProtection(), equals(), Linker::formatAutocommentsCallback(), getCascadeProtectionSources(), getLinksTo(), getNotificationTimestamp(), getRedirectsHere(), getSubjectPage(), getTalkPage(), Parser::getTemplateDom(), getTitleProtection(), isDeleted(), isDeletedQuick(), isSingleRevRedirect(), isSpecial(), isValidMoveOperation(), Parser::makeImage(), Linker::makeMediaLinkObj(), moveTo(), Linker::normaliseSpecialPage(), updateTitleProtection(), and userCanRead().
Title::getDefaultNamespace | ( | ) |
Title::getEarliestRevTime | ( | ) |
Title::getEditURL | ( | ) |
Title::getEscapedText | ( | ) |
Get the HTML-escaped displayable text form.
Used for the title field in tags.
Reimplemented in FakeTitle.
Definition at line 941 of file Title.php.
References getPrefixedText().
Title::getFirstRevision | ( | $ | flags = 0 |
) |
Title::getFragment | ( | ) |
Get the Title fragment (i.e. the bit after the #) in text form.
Reimplemented in FakeTitle.
Definition at line 612 of file Title.php.
Referenced by getLinkUrl(), and Linker::normaliseSpecialPage().
Title::getFragmentForURL | ( | ) |
Get the fragment in URL form, including the "#" character if there is one.
Definition at line 617 of file Title.php.
References escapeFragmentForURL().
Referenced by getFullURL(), and getLinkUrl().
Title::getFullText | ( | ) |
Get the prefixed title with spaces, plus any fragment (part beginning with '#').
Reimplemented in FakeTitle.
Definition at line 670 of file Title.php.
References $text, and getPrefixedText().
Referenced by getParentCategories().
Title::getFullURL | ( | $ | query = '' , |
|
$ | variant = false | |||
) |
Get a real URL referring to this title, with interwiki link and fragment.
$query | { String :,} 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). | |
$variant | String : : language variant of url (for sr, zh..) |
Reimplemented in FakeTitle.
Definition at line 736 of file Title.php.
References $url, $wgContLang, $wgRequest, $wgServer, Interwiki::fetch(), getFragmentForURL(), getNsText(), wfAppendQuery(), wfArrayToCGI(), wfRunHooks(), and wfUrlencode().
Referenced by escapeFullURL(), getLinkUrl(), getLocalURL(), and trackbackRDF().
Title::getIndexTitle | ( | ) |
Get title for search index.
Reimplemented in FakeTitle.
Definition at line 635 of file Title.php.
References indexTitle().
Title::getInternalURL | ( | $ | query = '' , |
|
$ | variant = false | |||
) |
Get the URL form for an internal link.
$query | String : : an optional query string | |
$variant | String : : language variant of url (for sr, zh..) |
Reimplemented in FakeTitle.
Definition at line 917 of file Title.php.
References $url, $wgInternalServer, getLocalURL(), and wfRunHooks().
Referenced by getSquidURLs().
Title::getInterwiki | ( | ) |
Title::getInterwikiLink | ( | $ | key | ) | [static] |
Returns the URL associated with an interwiki prefix.
$key | String : : the interwiki prefix (e.g. "MeatBall") |
Definition at line 483 of file Title.php.
References $key, and Interwiki::fetch().
Title::getLatestRevID | ( | $ | flags = 0 |
) |
What is the page_latest field for this page?
$flags | Integer : : a bit field; may be GAID_FOR_UPDATE to select for update |
Definition at line 2090 of file Title.php.
References $db, $flags, pageCond(), and wfGetDB().
Referenced by moveOverExistingRedirect().
Title::getLength | ( | $ | flags = 0 |
) |
What is the length of this page? Uses link cache, adding it if necessary.
$flags | Integer : : a bit field; may be GAID_FOR_UPDATE to select for update |
Definition at line 2072 of file Title.php.
References $flags, getArticleID(), and LinkCache::singleton().
Title::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.
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 |
Definition at line 2423 of file Title.php.
References $db, $options, $res, $row, getDBkey(), getNamespace(), makeTitle(), LinkCache::singleton(), and wfGetDB().
Referenced by getTemplateLinksTo().
Title::getLinkUrl | ( | $ | query = array() , |
|
$ | variant = false | |||
) |
Get a URL that's the simplest URL that will be valid to link, locally, to the current Title.
It includes the fragment, but does not include the server unless action=render is used (or the link is external). If there's a fragment but the prefixed text is empty, we just return a link to the fragment.
$query | { String :} : An associative array of key => value pairs for the query string. Keys and values will be escaped. | |
$variant | String : : Language variant of URL (for sr, zh..). Ignored for external links. Default is "false" (same variant as current page, for anonymous users). |
Definition at line 869 of file Title.php.
References getFragment(), getFragmentForURL(), getFullURL(), getLocalURL(), getPrefixedText(), isExternal(), wfProfileIn(), and wfProfileOut().
Title::getLocalURL | ( | $ | query = '' , |
|
$ | variant = false | |||
) |
Get a URL with no fragment or server name.
If this page is generated with action=render, $wgServer is prepended.
mixed | $query an optional query string; if not specified, $wgArticlePath will be used. Can be specified as an associative array as well, e.g., array( 'action' => 'edit' ) (keys and values will be URL-escaped). | |
$variant | String : : language variant of url (for sr, zh..) |
Reimplemented in FakeTitle.
Definition at line 782 of file Title.php.
References $action, $url, $wgActionPaths, $wgArticlePath, $wgContLang, $wgRequest, $wgScript, $wgServer, $wgUser, $wgVariantArticlePath, getFullURL(), getPrefixedDBkey(), isExternal(), wfAppendQuery(), wfArrayToCGI(), wfRunHooks(), and wfUrlencode().
Referenced by escapeLocalURL(), getEditURL(), getInternalURL(), getLinkUrl(), and Linker::makeThumbLink2().
Title::getNamespace | ( | ) |
Get the namespace index, i.e. one of the NS_xxxx constants.
Reimplemented in FakeTitle.
Definition at line 552 of file Title.php.
Referenced by TitleDependency::__construct(), deleteTitleProtection(), equals(), fixSpecialName(), Linker::formatAutocommentsCallback(), getArticleID(), getCascadeProtectionSources(), getLinksTo(), getNamespaceKey(), getNotificationTimestamp(), getRedirectsHere(), getSubjectPage(), getSubpages(), getTalkPage(), Parser::getTemplateDom(), getTitleProtection(), getUserPermissionsErrorsInternal(), isContentPage(), isDeleted(), isDeletedQuick(), isMovable(), isProtected(), isSingleRevRedirect(), isSpecial(), isTalkPage(), isValidMoveOperation(), isWatchable(), moveOverExistingRedirect(), moveSubpages(), moveTo(), moveToNewTitle(), Linker::normaliseSpecialPage(), Parser::statelessFetchTemplate(), touchLinks(), updateTitleProtection(), and userCanRead().
Title::getNamespaceKey | ( | ) |
Generate strings used for xml 'id' names in monobook tabs.
Definition at line 3537 of file Title.php.
References $wgContLang, getNamespace(), and getSubjectNsText().
Title::getNextRevisionID | ( | $ | revId, | |
$ | flags = 0 | |||
) |
Title::getNotificationTimestamp | ( | $ | user = NULL |
) |
Get the timestamp when this page was updated since the user last saw it.
User | $user |
Definition at line 3467 of file Title.php.
References $dbr, $user, $wgShowUpdatedMarker, $wgUser, getDBkey(), getNamespace(), and wfGetDB().
Title::getNsText | ( | ) |
Get the namespace text.
Reimplemented in FakeTitle.
Definition at line 557 of file Title.php.
References $wgCanonicalNamespaceNames, and $wgContLang.
Referenced by getFullURL(), getUserPermissionsErrorsInternal(), isValidMoveOperation(), and prefix().
Title::getParentCategories | ( | ) |
Get categories to which this Title belongs and return an array of categories' names.
Reimplemented in FakeTitle.
Definition at line 3154 of file Title.php.
References $dbr, $res, $row, $sql, $wgContLang, getFullText(), and wfGetDB().
Referenced by getParentCategoryTree().
Title::getParentCategoryTree | ( | $ | children = array() |
) |
Get a tree of parent categories.
$children | : an array with the children in the keys, to check for circular refs |
Definition at line 3185 of file Title.php.
References getParentCategories(), and newFromText().
Title::getPartialURL | ( | ) |
Title::getPrefixedDBkey | ( | ) |
Get the prefixed database key form.
Reimplemented in FakeTitle.
Definition at line 644 of file Title.php.
Referenced by getLocalURL(), Parser::getTemplateDom(), isValidMoveTarget(), Linker::makeImageLink2(), moveTo(), resetArticleID(), and trackbackURL().
Title::getPrefixedText | ( | ) |
Get the prefixed title with spaces.
This is the form usually used for display
Reimplemented in FakeTitle.
Definition at line 655 of file Title.php.
Referenced by __toString(), Linker::buildRollbackLink(), getEscapedText(), getFullText(), getLinkUrl(), Linker::makeBrokenImageLinkObj(), moveOverExistingRedirect(), moveTo(), moveToNewTitle(), and userCanRead().
Title::getPrefixedURL | ( | ) |
Title::getPreviousRevisionID | ( | $ | revId, | |
$ | flags = 0 | |||
) |
Title::getRedirectsHere | ( | $ | ns = null |
) |
Get all extant redirects to this Title.
$ns | { Integer :, Null :} Single namespace to consider; NULL to consider all namespaces |
Definition at line 3622 of file Title.php.
References $dbr, $ns, $res, $row, getDBkey(), getNamespace(), newFromRow(), and wfGetDB().
Title::getRestrictionExpiry | ( | $ | action | ) |
Get the expiry time for the restriction against a given action.
Definition at line 1970 of file Title.php.
References $action, and loadRestrictions().
Title::getRestrictions | ( | $ | action | ) |
Accessor/initialisation for mRestrictions.
$action | String : : action that permission needs to be checked for |
Reimplemented in FakeTitle.
Definition at line 1956 of file Title.php.
References $action, and loadRestrictions().
Referenced by getUserPermissionsErrorsInternal(), isProtected(), isSemiProtected(), and updateTitleProtection().
Title::getSkinFromCssJsSubpage | ( | ) |
Trim down a .css or .js subpage title to get the corresponding skin name.
Reimplemented in FakeTitle.
Definition at line 1685 of file Title.php.
Referenced by isValidCssJsSubpage().
Title::getSquidURLs | ( | ) |
Get a list of URLs to purge from the Squid cache when this page changes.
Reimplemented in FakeTitle.
Definition at line 2511 of file Title.php.
References $urls, $wgContLang, and getInternalURL().
Referenced by moveOverExistingRedirect(), and purgeSquid().
Title::getSubjectNsText | ( | ) |
Get the namespace text of the subject (rather than talk) page.
Reimplemented in FakeTitle.
Definition at line 584 of file Title.php.
References $wgContLang, and MWNamespace::getSubject().
Referenced by getNamespaceKey().
Title::getSubjectPage | ( | ) |
Get a title object associated with the subject page of this talk page.
Reimplemented in FakeTitle.
Definition at line 2404 of file Title.php.
References getDBkey(), getNamespace(), MWNamespace::getSubject(), and makeTitle().
Title::getSubpages | ( | $ | limit = -1 |
) |
Get all subpages of this page.
$limit | Maximum number of subpages to fetch; -1 for no limit |
Definition at line 1630 of file Title.php.
References $conds, $dbr, $options, getNamespace(), MWNamespace::hasSubpages(), TitleArray::newFromResult(), and wfGetDB().
Referenced by hasSubpages(), and moveSubpages().
Title::getSubpageText | ( | ) |
Get the lowest-level subpage name, i.e.
the rightmost part after /
Definition at line 698 of file Title.php.
References MWNamespace::hasSubpages().
Referenced by getSubpageUrlForm().
Title::getSubpageUrlForm | ( | ) |
Get a URL-encoded form of the subpage text.
Definition at line 710 of file Title.php.
References $text, getSubpageText(), and wfUrlencode().
Title::getTalkNsText | ( | ) |
Get the namespace text of the talk page.
Definition at line 592 of file Title.php.
References $wgContLang, and MWNamespace::getTalk().
Title::getTalkPage | ( | ) |
Get a Title object associated with the talk page of this article.
Reimplemented in FakeTitle.
Definition at line 2394 of file Title.php.
References getDBkey(), getNamespace(), MWNamespace::getTalk(), and makeTitle().
Title::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 |
Definition at line 2464 of file Title.php.
References $options, and getLinksTo().
Title::getText | ( | ) |
Simple accessors.
Get the text form (spaces not underscores) of the main part
Reimplemented in FakeTitle.
Definition at line 537 of file Title.php.
Referenced by getBaseText(), isSubpage(), Linker::makeMediaLinkObj(), Parser::statelessFetchTemplate(), and trackbackRDF().
Title::getTitleProtection | ( | ) | [private] |
Is this title subject to title protection?
Definition at line 1385 of file Title.php.
References $dbr, $res, $row, getDBkey(), getNamespace(), and wfGetDB().
Referenced by getUserPermissionsErrorsInternal(), and loadRestrictions().
Title::getTouched | ( | $ | db = NULL |
) |
Title::getUserCaseDBKey | ( | ) |
Title::getUserPermissionsErrors | ( | $ | action, | |
$ | user, | |||
$ | doExpensiveQueries = true , |
|||
$ | ignoreErrors = array() | |||
) |
Can $user perform $action on this page?
FIXME: This *does not* check throttles (User::pingLimiter()).
$action | String : :action that permission needs to be checked for | |
$user | User : user to check | |
$doExpensiveQueries | Boolean : : Set this to false to avoid doing unnecessary queries. | |
$ignoreErrors | { String :} : Set this to a list of message keys whose corresponding errors may be ignored. |
Definition at line 1076 of file Title.php.
References $action, $error, $name, $reason, $user, $wgContLang, $wgEmailConfirmToEdit, $wgLang, $wgUser, getUserPermissionsErrorsInternal(), StubObject::isRealObject(), wfGetIP(), wfMsg(), wfTimestamp(), and User::whoIs().
Referenced by getUserPermissionsErrorsInternal(), and isValidMoveOperation().
Title::getUserPermissionsErrorsInternal | ( | $ | action, | |
$ | user, | |||
$ | doExpensiveQueries = true , |
|||
$ | short = false | |||
) | [private] |
Can $user perform $action on this page? This is an internal function, which checks ONLY that previously checked by userCan (i.e.
it leaves out checks on wfReadOnly() and blocks)
$action | String : : action that permission needs to be checked for | |
$user | User : user to check | |
$doExpensiveQueries | Boolean : : Set this to false to avoid doing unnecessary queries. | |
$short | Boolean : : Set this to true to stop after the first permission error. |
Definition at line 1167 of file Title.php.
References $action, $ns, $page, $result, $user, getCascadeProtectionSources(), User::getGroupsWithPermission(), getNamespace(), getNsText(), getRestrictions(), getTitleProtection(), getUserPermissionsErrors(), isCssJsSubpage(), isMovable(), MWNamespace::isMovable(), isNamespaceProtected(), isSubpage(), isTalkPage(), wfMsg(), wfProfileIn(), wfProfileOut(), wfRunHooks(), and User::whoIs().
Referenced by getUserPermissionsErrors(), and userCan().
Title::hasSubpages | ( | ) |
Does this have subpages? (Warning, usually requires an extra DB query.
)
Definition at line 1604 of file Title.php.
References getSubpages(), and MWNamespace::hasSubpages().
Referenced by isSubpage().
static Title::indexTitle | ( | $ | ns, | |
$ | title | |||
) | [static] |
Get a string representation of a title suitable for including in a search index.
$ns | Integer : : a namespace index | |
$title | String : : text-form main part |
Definition at line 437 of file Title.php.
References $ns, $t, $title, $wgContLang, and SearchEngine::legalSearchChars().
Referenced by SearchUpdate::doUpdate(), and getIndexTitle().
Title::invalidateCache | ( | ) |
Updates page_touched for this page; called from LinksUpdate.php.
Reimplemented in FakeTitle.
Definition at line 2123 of file Title.php.
References $dbw, $success, HTMLFileCache::clearFileCache(), pageCond(), wfGetDB(), and wfReadOnly().
Title::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 in FakeTitle.
Definition at line 3390 of file Title.php.
References exists(), wfFindFile(), and wfMsgWeirdKey().
Referenced by isKnown().
Title::isCascadeProtected | ( | ) |
Cascading protection: Return true if cascading restrictions apply to this page, false if not.
Definition at line 1721 of file Title.php.
References getCascadeProtectionSources().
Title::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?
Definition at line 3611 of file Title.php.
References getNamespace(), and MWNamespace::isContent().
Referenced by moveTo().
Title::isCssJsSubpage | ( | ) |
Is this a .css or .js subpage of a user page?
Reimplemented in FakeTitle.
Definition at line 1666 of file Title.php.
Referenced by getUserPermissionsErrorsInternal(), and isValidCssJsSubpage().
Title::isCssOrJsPage | ( | ) |
Title::isCssSubpage | ( | ) |
Title::isDeleted | ( | ) |
Is there a version of this page in the deletion archive?
Reimplemented in FakeTitle.
Definition at line 1981 of file Title.php.
References $dbr, $n, getDBkey(), getNamespace(), and wfGetDB().
Title::isDeletedQuick | ( | ) |
Is there a version of this page in the deletion archive?
Definition at line 2004 of file Title.php.
References $dbr, getDBkey(), getNamespace(), and wfGetDB().
Title::isExternal | ( | ) |
Is this Title interwiki?
Reimplemented in FakeTitle.
Definition at line 949 of file Title.php.
Referenced by getLinkUrl(), getLocalURL(), and isWatchable().
Title::isJsSubpage | ( | ) |
Title::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).
Reimplemented in FakeTitle.
Definition at line 3423 of file Title.php.
References exists(), and isAlwaysKnown().
Title::isLocal | ( | ) |
Determine whether the object refers to a page within this project.
Reimplemented in FakeTitle.
Definition at line 494 of file Title.php.
References Interwiki::fetch().
Title::isMovable | ( | ) |
Would anybody with sufficient privileges be able to move this page? Some pages just aren't movable.
Reimplemented in FakeTitle.
Definition at line 1501 of file Title.php.
References getInterwiki(), and getNamespace().
Referenced by getUserPermissionsErrorsInternal(), and isValidMoveOperation().
Title::isNamespaceProtected | ( | ) |
Determines if $wgUser is unable to edit this page because it has been protected by $wgNamespaceProtection.
Definition at line 1043 of file Title.php.
References $wgNamespaceProtection, and $wgUser.
Referenced by getUserPermissionsErrorsInternal().
Title::isNewPage | ( | ) |
Check if this is a new page.
Definition at line 3288 of file Title.php.
References $dbr, pageCond(), and wfGetDB().
Title::isProtected | ( | $ | action = '' |
) |
Does the title correspond to a protected article?
$what | String : : the action the page is protected from, by default checks move and edit |
Reimplemented in FakeTitle.
Definition at line 982 of file Title.php.
References $action, $type, $wgRestrictionLevels, $wgRestrictionTypes, getNamespace(), and getRestrictions().
Referenced by moveTo().
Title::isRedirect | ( | $ | flags = 0 |
) |
Is this an article that is a redirect page? Uses link cache, adding it if necessary.
$flags | Integer : : a bit field; may be GAID_FOR_UPDATE to select for update |
Definition at line 2053 of file Title.php.
References $flags, getArticleID(), and LinkCache::singleton().
Title::isSemiProtected | ( | $ | action = 'edit' |
) |
Title::isSingleRevRedirect | ( | ) |
Checks if this page is just a one-rev redirect.
Adds lock, so don't use just for light purposes.
Definition at line 3063 of file Title.php.
References $dbw, $row, getDBkey(), getNamespace(), pageCond(), and wfGetDB().
Title::isSpecial | ( | $ | name | ) |
Returns true if this title resolves to the named special page.
$name | String : : The special page name |
Definition at line 3577 of file Title.php.
References $name, getDBkey(), getNamespace(), and SpecialPage::resolveAliasWithSubpage().
Referenced by isValidRedirectTarget(), and userCanRead().
Title::isSubpage | ( | ) |
Is this a subpage?
Definition at line 1594 of file Title.php.
References getText(), and hasSubpages().
Referenced by getUserPermissionsErrorsInternal().
Title::isTalkPage | ( | ) |
Is this a talk page of some sort?
Reimplemented in FakeTitle.
Definition at line 1586 of file Title.php.
References getNamespace(), and MWNamespace::isTalk().
Referenced by getUserPermissionsErrorsInternal().
Title::isTrans | ( | ) |
Determine whether the object refers to a page within this project and is transcludable.
Reimplemented in FakeTitle.
Definition at line 508 of file Title.php.
References Interwiki::fetch().
Title::isValidCssJsSubpage | ( | ) |
Is this a *valid* .css or .js subpage of a user page? Check that the corresponding skin exists.
Reimplemented in FakeTitle.
Definition at line 1674 of file Title.php.
References getSkinFromCssJsSubpage(), Skin::getSkinNames(), and isCssJsSubpage().
Title::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 | |
$auth | Boolean : : indicates whether $wgUser's permissions should be checked | |
$reason | String : : is the log summary of the move, used for spam checking |
Definition at line 2560 of file Title.php.
References $file, $reason, $wgUser, File::checkExtensionCompatibility(), equals(), exists(), getArticleID(), getDBkey(), getNamespace(), getNsText(), getUserPermissionsErrors(), isMovable(), isValidMoveTarget(), EditPage::matchSummarySpamRegex(), wfLocalFile(), wfMergeErrorArrays(), wfRunHooks(), and wfStripIllegalFilenameChars().
Referenced by moveTo().
Title::isValidMoveTarget | ( | $ | nt | ) |
Checks if $this can be moved to a given Title
&$nt | Title : the new title to check |
Definition at line 3101 of file Title.php.
References $dbw, $file, $text, getPrefixedDBkey(), newFromText(), Revision::newFromTitle(), wfDebug(), wfGetDB(), and wfLocalFile().
Referenced by isValidMoveOperation().
Title::isValidRedirectTarget | ( | ) |
Check if this Title is a valid redirect target.
Definition at line 3652 of file Title.php.
References $wgInvalidRedirectTargets, and isSpecial().
Title::isWatchable | ( | ) |
Can this title be added to a user's watchlist?
Definition at line 3143 of file Title.php.
References getNamespace(), and isExternal().
static Title::legalChars | ( | ) | [static] |
Get a regex character class describing the legal characters in a link.
Definition at line 423 of file Title.php.
References $wgLegalTitleChars.
Referenced by languages::getMessagesWithDubiousLinks(), Parser_LinkHooks::replaceInternalLinks2(), Parser::replaceInternalLinks2(), secureAndSplit(), and wfStripIllegalFilenameChars().
Title::loadRestrictions | ( | $ | oldFashionedRestrictions = NULL |
) |
Load restrictions from the page_restrictions table.
Reimplemented in FakeTitle.
Definition at line 1903 of file Title.php.
References $dbr, $res, Block::decodeExpiry(), exists(), getTitleProtection(), loadRestrictionsFromRow(), purgeExpiredRestrictions(), wfGetDB(), and wfTimestampNow().
Referenced by areRestrictionsCascading(), getRestrictionExpiry(), and getRestrictions().
Title::loadRestrictionsFromRow | ( | $ | res, | |
$ | oldFashionedRestrictions = NULL | |||
) | [private] |
Loads a string into mRestrictions array.
$res | Resource : restrictions as an SQL result. |
Definition at line 1829 of file Title.php.
References $dbr, $res, $row, $type, $wgRestrictionTypes, Block::decodeExpiry(), purgeExpiredRestrictions(), wfGetDB(), and wfTimestampNow().
Referenced by loadRestrictions().
static Title::makeName | ( | $ | ns, | |
$ | title, | |||
$ | fragment = '' | |||
) | [static] |
Definition at line 464 of file Title.php.
References $name, $ns, $title, and $wgContLang.
Referenced by MovePageForm::doSubmit(), LinkHolderArray::doVariants(), makeTitleSafe(), and nameOf().
static& Title::makeTitle | ( | $ | ns, | |
$ | title, | |||
$ | fragment = '' | |||
) | [static] |
Create a new Title from a namespace index and a DB key.
It's assumed that $ns and $title are *valid*, for instance when they came directly from the database or a special page name. For convenience, spaces are converted to underscores so that eg user_text fields can be used directly.
$ns | Integer : : the namespace of the article | |
$title | String : : the unprefixed database key form | |
$fragment | String : : The link fragment (after the "#") |
Definition at line 250 of file Title.php.
References $ns, $t, $title, and wfUrlencode().
Referenced by SearchResult::__construct(), LinkBatch::addResultToCache(), UploadForm::ajaxGetLicensePreview(), MediaWiki::articleFromTitle(), LocalRepo::checkRedirect(), checkSeparation(), compressWithConcat(), deleteDefaultMessages(), CategoryViewer::doCategoryQuery(), RestrictUserForm::doNamespaceRestriction(), RestrictUserForm::doPageRestriction(), SpecialTags::doTagRow(), IPUnblockForm::doUnblock(), LinkHolderArray::doVariants(), ApiQueryDeletedrevs::execute(), ApiQueryBacklinks::extractRedirRowInfo(), ApiQueryWatchlist::extractRowInfo(), ApiQueryContributions::extractRowInfo(), ApiQueryRecentChanges::extractRowInfo(), ApiQueryRandom::extractRowInfo(), ApiQueryLogEvents::extractRowInfo(), ApiQueryBacklinks::extractRowInfo(), Article::fetchContent(), SpecialRecentChanges::filterByCategories(), ForeignAPIRepo::findBySha1(), DoubleRedirectJob::fixRedirects(), fixSpecialName(), ImagePage::followRedirect(), FeedUtils::formatDiff(), ApiParse::formatLinks(), WantedTemplatesPage::formatResult(), WantedFilesPage::formatResult(), WantedCategoriesPage::formatResult(), UnwatchedpagesPage::formatResult(), UnusedtemplatesPage::formatResult(), UnusedCategoriesPage::formatResult(), PopularPagesPage::formatResult(), MostrevisionsPage::formatResult(), MostlinkedCategoriesPage::formatResult(), MIMEsearchPage::formatResult(), ListredirectsPage::formatResult(), LinkSearchPage::formatResult(), FileDuplicateSearchPage::formatResult(), DoubleRedirectsPage::formatResult(), DisambiguationsPage::formatResult(), BrokenRedirectsPage::formatResult(), AncientPagesPage::formatResult(), UsersPager::formatRow(), DeletedContribsPager::formatRow(), CategoryPager::formatRow(), ImageListPager::formatValue(), ParserTest::fuzzTest(), ChangesFeed::generateFeed(), GenerateSitemap::generateLimit(), getBrokenLinksFrom(), User::getCanonicalName(), getCascadeProtectionSources(), UploadForm::getDupeWarning(), UploadForm::getExistsWarning(), DoubleRedirectJob::getFinalDestination(), Article::getHiddenCategories(), SpecialExport::getLinks(), getLinksTo(), RecentChange::getMovedToTitle(), MessageCache::getMsgFromNamespace(), SearchEngine::getNearMatch(), ApiQueryInfo::getProtectionInfo(), SpecialMytalk::getRedirect(), SpecialMypage::getRedirect(), File::getRedirectedTitle(), ImagePage::getRedirectTarget(), Article::getRedirectTarget(), ApiPageSet::getRedirectTargets(), DisambiguationsPage::getSQL(), getSubjectPage(), getTalkPage(), Parser::getTemplateDom(), EditPage::getTemplates(), Revision::getTitle(), RecentChange::getTitle(), TitleDependency::getTitle(), SpecialPage::getTitleFor(), LogPage::getTitleLink(), Article::getUsedTemplates(), UserRightsProxy::getUserPage(), User::getUserPage(), ImagePage::imageLinks(), ApiPageSet::initFromQueryResult(), SpecialRevisionDelete::logLine(), LogEventsList::logLine(), GenerateSitemap::main(), SkinMonoBookCBT::makeSpecialParamUrl(), newFromID(), newFromIDs(), SquidUpdate::newFromLinksTo(), newFromRow(), OldLocalFile::newFromRow(), ForeignDBFile::newFromRow(), ArchivedFile::newFromRow(), XmlDumpWriter::openPage(), WikiImporter::out_append(), ImageCleanup::pokeFile(), ApiPageSet::processDbRow(), WatchlistCleanup::processPage(), TitleCleanup::processPage(), CapsCleanup::processPage(), LinkHolderArray::replaceInternal(), Revision::Revision(), DoubleRedirectJob::run(), ApiQueryWatchlistRaw::run(), ApiQueryProtectedTitles::run(), ApiQueryLinks::run(), ApiQueryImages::run(), ApiQueryExtLinksUsage::run(), ApiQueryDuplicateFiles::run(), ApiQueryCategoryMembers::run(), ApiQueryCategories::run(), ApiQueryBacklinks::run(), ApiQueryAllpages::run(), ApiQueryAllLinks::run(), ApiQueryAllimages::run(), ApiQueryAllCategories::run(), ParserTest::runTest(), RecentChange::save(), SpecialAllpages::showChunk(), WhatLinksHerePage::showIndirectLinks(), SpecialPrefixindex::showPrefixChunk(), PrefixSearch::specialSearch(), updateSearchIndex(), CoreParserFunctions::urlFunction(), Linker::userLink(), Linker::userTalkLink(), ImagePage::view(), wfAllMessagesMakeHTMLText(), wfSpecialLinkSearch(), wfSpecialNewimages(), wfSpecialRemoveRestrictionsProcess(), and XmlDumpWriter::writeLogItem().
static Title::makeTitleSafe | ( | $ | ns, | |
$ | title, | |||
$ | fragment = '' | |||
) | [static] |
Create a new Title from a namespace index and a DB key.
The parameters will be checked for validity, which is a bit slower than makeTitle() but safer for user-provided data.
$ns | Integer : : the namespace of the article | |
$title | String : : the database key form | |
$fragment | String : : The link fragment (after the "#") |
Definition at line 272 of file Title.php.
References $ns, $t, $title, and makeName().
Referenced by UsersPager::__construct(), UnregisteredLocalFile::__construct(), OutputPage::addCategoryLinks(), ProtectionForm::buildForm(), WatchlistEditor::buildRemoveList(), ImageCleanup::buildSafeTitle(), Parser::doDoubleUnderscore(), MovePageForm::doSubmit(), SpecialExport::execute(), DeletedContributionsPage::execute(), SpecialContributions::execute(), ApiQueryInfo::execute(), SpecialContributions::feed(), FileRepo::findFile(), FileCache::findFile(), RepoGroup::findFiles(), FileCache::findFiles(), SpecialNewpages::form(), Linker::formatAutocommentsCallback(), WantedPagesPage::formatResult(), ShortPagesPage::formatResult(), SpecialMostlinkedtemplates::formatResult(), MostlinkedPage::formatResult(), MostcategoriesPage::formatResult(), FewestrevisionsPage::formatResult(), PageQueryPage::formatResult(), ProtectedTitlesForm::formatRow(), ProtectedPagesForm::formatRow(), SpecialNewpages::formatRow(), UsersPager::getBody(), CategoryPager::getBody(), LinksUpdate::getCategoryInsertions(), SpecialStatistics::getMostViewedPages(), SpecialAllpages::getNamespaceKeyAndText(), ApiBase::getParameterFromSettings(), NewPagesPager::getQueryInfo(), RandomPage::getRandomTitle(), SpecialPage::getSafeTitleFor(), DisambiguationsPage::getSQL(), MergeHistoryPager::getStartBody(), LogPager::getStartBody(), Category::getTitle(), WatchlistEditor::getWatchlist(), WatchlistEditor::getWatchlistInfo(), User::idFromName(), UploadForm::internalProcessUpload(), Parser::limitationWarn(), LogPager::limitUser(), PreferencesForm::mainPrefsForm(), UploadForm::mainUploadForm(), Linker::makeMediaLink(), makeNSUrl(), Linker::makeThumbLink2(), TitleCleanup::moveInconsistentPage(), moveSubpages(), FileRepo::newFile(), Image::newFromName(), Category::newFromName(), LanguageConverter::parseCachedTable(), ApiQueryBacklinks::parseContinueParam(), Job::pop(), Job::pop_type(), ImageQueryPage::prepareImage(), ImageCleanup::processPage(), PatrolLog::record(), NamespaceConflictChecker::reportConflict(), NamespaceConflictChecker::resolveConflict(), NamespaceConflictChecker::resolveConflictOn(), IPBlockForm::setUsernameBitfields(), UndeleteForm::showHistory(), UndeleteForm::showList(), SpecialBookSources::showList(), SpecialAllpages::showToplevel(), wfSpecialFilepath(), and wfThumbMain().
Title::moveNoAuth | ( | &$ | nt | ) |
Title::moveOverExistingRedirect | ( | &$ | nt, | |
$ | reason = '' , |
|||
$ | createRedirect = true | |||
) | [private] |
Move page to a title which is at present a redirect to the source page.
&$nt | Title : the page to move to, which should currently be a redirect | |
$reason | String : : The reason for the move | |
$createRedirect | Boolean : : Whether to leave a redirect at the old title. Ignored if the user doesn't have the suppressredirect right |
Definition at line 2789 of file Title.php.
References $dbw, $file, $fname, $reason, $status, $u, $urls, $wgUser, $wgUseSquid, $wgUseTrackbacks, MagicWord::get(), getArticleID(), getLatestRevID(), getNamespace(), getPrefixedText(), getSquidURLs(), Revision::newNullRevision(), resetArticleID(), wfGetDB(), wfLocalFile(), wfMsgForContent(), wfRunHooks(), and wfTimestampNow().
Referenced by moveTo().
Title::moveSubpages | ( | $ | nt, | |
$ | auth = true , |
|||
$ | reason = '' , |
|||
$ | createRedirect = true | |||
) |
Move this page's subpages to be subpages of $nt.
$nt | Title Move target | |
$auth | bool Whether $wgUser's permissions should be checked | |
$reason | string The reason for the move | |
$createRedirect | bool Whether to create redirects from the old subpages to the new ones Ignored if the user doesn't have the 'suppressredirect' right |
Definition at line 3006 of file Title.php.
References $count, $reason, $success, $wgMaximumMovedPages, $wgUser, MWNamespace::getCanonicalName(), getNamespace(), getSubpages(), MWNamespace::hasSubpages(), makeTitleSafe(), and userCan().
Title::moveTo | ( | &$ | nt, | |
$ | auth = true , |
|||
$ | reason = '' , |
|||
$ | createRedirect = true | |||
) |
Move a title to a new location.
&$nt | Title : the new title | |
$auth | Boolean : : indicates whether $wgUser's permissions should be checked | |
$reason | String : : The reason for the move | |
$createRedirect | Boolean : : Whether to create a redirect from the old title to the new title. Ignored if the user doesn't have the suppressredirect right. |
Definition at line 2659 of file Title.php.
References $dbw, $reason, $u, $wgMessageCache, $wgUser, WatchedItem::duplicateEntries(), getArticleID(), getDBkey(), getNamespace(), getPrefixedDBkey(), getPrefixedText(), isContentPage(), isProtected(), isValidMoveOperation(), moveOverExistingRedirect(), wfGetDB(), wfMsgForContent(), and wfRunHooks().
Referenced by moveNoAuth().
Title::moveToNewTitle | ( | &$ | nt, | |
$ | reason = '' , |
|||
$ | createRedirect = true | |||
) | [private] |
Move page to non-existing title.
&$nt | {Title} the new Title | |
$reason | {} The reason for the move | |
$createRedirect | {} Whether to create a redirect from the old title to the new title Ignored if the user doesn't have the suppressredirect right |
Definition at line 2906 of file Title.php.
References $dbw, $file, $fname, $reason, $status, $wgUser, $wgUseSquid, MagicWord::get(), getArticleID(), getNamespace(), getPrefixedText(), Revision::newNullRevision(), Article::onArticleCreate(), purgeSquid(), resetArticleID(), wfGetDB(), wfLocalFile(), wfMsgExt(), wfMsgForContent(), and wfRunHooks().
static Title::nameOf | ( | $ | id | ) | [static] |
static Title::newFromDBkey | ( | $ | key | ) | [static] |
Create a new Title from a prefixed DB key.
$key | {} The database key, which has underscores instead of spaces, possibly including namespace and interwiki prefixes |
Definition at line 89 of file Title.php.
Referenced by LinkCache::addLink(), LinkHolderArray::doVariants(), and wfAjaxWatch().
static Title::newFromID | ( | $ | id, | |
$ | flags = 0 | |||
) | [static] |
Create a new Title from an article ID.
$id | Integer : : the page_id corresponding to the Title to create | |
$flags | Integer : : use GAID_FOR_UPDATE to use master |
Definition at line 189 of file Title.php.
References $db, $flags, $fname, $row, $title, makeTitle(), and wfGetDB().
Referenced by MediaWiki::checkInitialQueries(), cleanupArticle(), ApiMove::execute(), ApiDelete::execute(), fixLinksFromArticle(), fixRedirect(), DisambiguationsPage::formatResult(), and MergehistoryForm::merge().
static Title::newFromIDs | ( | $ | ids | ) | [static] |
static Title::newFromRedirect | ( | $ | text | ) | [static] |
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.
$text | String : : Text with possible redirect |
Definition at line 304 of file Title.php.
References $text, and newFromRedirectInternal().
Referenced by ListredirectsPage::formatResult(), Article::getAutosummary(), Article::insertRedirect(), EditPage::internalAttemptSave(), Article::isRedirect(), DoubleRedirectJob::run(), Parser::statelessFetchTemplate(), and Article::updateRevisionOn().
static Title::newFromRedirectArray | ( | $ | text | ) | [static] |
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).
$text | String : : Text with possible redirect |
Definition at line 331 of file Title.php.
References $text, $title, $wgMaxRedirects, and newFromRedirectInternal().
Referenced by EditPage::getPreviewText(), newFromRedirectRecurse(), and Article::view().
static Title::newFromRedirectInternal | ( | $ | text | ) | [static, protected] |
Really extract the redirect destination Do not call this function directly, use one of the newFromRedirect* functions above.
$text | String : : Text with possible redirect |
Definition at line 368 of file Title.php.
References $text, $title, MagicWord::get(), and newFromText().
Referenced by newFromRedirect(), and newFromRedirectArray().
static Title::newFromRedirectRecurse | ( | $ | text | ) | [static] |
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.
$text | String : : Text with possible redirect |
Definition at line 317 of file Title.php.
References $text, and newFromRedirectArray().
Referenced by Article::followRedirectText(), and Article::isRedirect().
static Title::newFromRow | ( | $ | row | ) | [static] |
Make a Title object from a DB row.
$row | Row : (needs at least page_title,page_namespace) |
Definition at line 227 of file Title.php.
References $row, $t, and makeTitle().
Referenced by ContribsPager::formatRow(), File::getLinksTo(), getRedirectsHere(), and TitleArrayFromResult::setCurrent().
static Title::newFromText | ( | $ | text, | |
$ | defaultNamespace = NS_MAIN | |||
) | [static] |
Create a new Title from text, such as what one would find in a link.
De- codes any HTML entities in the text.
$text | string The link text; spaces, prefixes, and an initial ':' indicating the main namespace are accepted. | |
$defaultNamespace | int The namespace to use if none is speci- fied by a prefix. If you want to force a specific namespace even if $text might begin with a namespace prefix, use makeTitle() or makeTitleSafe(). |
Definition at line 110 of file Title.php.
References $t, $text, $titleCache, and Sanitizer::decodeCharReferences().
Referenced by DoubleRedirectJob::__construct(), ParserTest::addArticle(), ApiQueryLogEvents::addLogParams(), Skin::addMetadataLinks(), addWiki(), ApiQuerySiteinfo::appendGeneralInfo(), ApiQuerySiteinfo::appendRightsInfo(), CoreParserFunctions::basepagename(), CoreParserFunctions::basepagenamee(), Parser::braceSubstitution(), SkinTemplate::buildPersonalUrls(), buildSidebar(), checkTitle(), ApiFeedWatchlist::createFeedItem(), CoreParserFunctions::displaytitle(), SpecialExport::doExport(), RestrictUserForm::doPageRestriction(), drawCategoryBrowser(), Linker::editSectionLinkForOther(), SpecialResetpass::execute(), ApiWatch::execute(), ApiUndelete::execute(), ApiRollback::execute(), ApiQueryLogEvents::execute(), ApiPurge::execute(), ApiProtect::execute(), ApiParse::execute(), ApiMove::execute(), ApiExpandTemplates::execute(), ApiEditPage::execute(), ApiDelete::execute(), EditPage::extractMetaDataFromArticle(), WatchlistEditor::extractTitles(), DBConnectionError::fileCachedPage(), LanguageConverter::findVariantLink(), Linker::formatAutocommentsCallback(), Parser::formatHeadings(), CoreParserFunctions::fullpagename(), CoreParserFunctions::fullpagenamee(), CoreParserFunctions::gender(), User::getCanonicalName(), getCategoryLinks(), SpecialListUserRestrictionsForm::getConds(), UploadForm::getExistsWarning(), User::getGroupPage(), RecentChange::getIRCLine(), SpecialExport::getLinks(), SearchEngine::getNearMatch(), getParentCategoryTree(), EditPage::getPreloadedText(), DisambiguationsPage::getSQL(), LogPage::getTitleLink(), SpecialSearchOld::goResult(), SpecialSearch::goResult(), LogImporter::importLine(), isValidMoveTarget(), User::isValidUserName(), SkinMonoBookCBT::language_urls(), LogPager::limitTitle(), PageArchive::listPagesByPrefix(), LogEventsList::logLine(), SkinTemplate::makeArticleUrlDetails(), Linker::makeBrokenLink(), makeI18nUrl(), Parser::makeImage(), Linker::makeKnownLink(), makeKnownUrlDetails(), Linker::makeLink(), Linker::makeStubLink(), SkinTemplate::makeTalkUrlDetails(), PPFuzzTester::makeTitle(), makeUrl(), makeUrlDetails(), TitleCleanup::moveIllegalPage(), CoreParserFunctions::mwnamespace(), nameAndLogin(), CoreParserFunctions::namespacee(), ImportStreamSource::newFromInterwiki(), newFromRedirectInternal(), newMainPage(), NukeNS(), NukePage(), otherLanguages(), WikiImporter::out_append(), SkinTemplate::outputPage(), WikiExporter::pageByName(), CoreParserFunctions::pagename(), CoreParserFunctions::pagenamee(), RdfMetaData::pageOrString(), RestrictUserForm::pageRestrictionForm(), CoreParserFunctions::pagesize(), SpecialSearch::powerSearchBox(), ApiQueryBacklinks::processContinue(), WatchlistCleanup::processPage(), TitleCleanup::processPage(), ApiPageSet::processTitlesArray(), EnhancedChangesList::recentChangesBlockLine(), OldChangesList::recentChangesLine(), Parser::renderImageGallery(), Parser::replaceInternalLinks2(), Parser_LinkHooks::replaceInternalLinksCallback(), OutputPage::returnToMain(), RdfMetaData::rights(), ApiQueryCategoryMembers::run(), ApiQueryCategories::run(), MWGearmanJob::runNoSwitch(), SearchUpdate::SearchUpdate(), Parser::setTitle(), SpecialSearchOld::setupPage(), SpecialSearch::shortDialog(), EditPage::showCustomIntro(), SpecialSearchOld::showInterwikiHit(), SpecialSearch::showInterwikiHit(), SpecialSearch::showResults(), WatchlistEditor::showTitles(), CoreParserFunctions::subjectpagename(), CoreParserFunctions::subjectpagenamee(), CoreParserFunctions::subjectspace(), CoreParserFunctions::subjectspacee(), CoreParserFunctions::subpagename(), CoreParserFunctions::subpagenamee(), subPageSubtitle(), LoginForm::successfulLogin(), CoreParserFunctions::talkpagename(), CoreParserFunctions::talkpagenamee(), CoreParserFunctions::talkspace(), CoreParserFunctions::talkspacee(), Parser::testPreprocess(), Parser::testPst(), Parser::testSrvus(), PrefixSearch::titleSearch(), ApiQueryBase::titleToKey(), WatchlistEditor::unwatchTitles(), CoreParserFunctions::urlFunction(), WatchlistEditor::watchTitles(), wfIsBadImage(), wfSpecialFileDuplicateSearch(), wfSpecialMovepage(), wfSpecialNewimages(), and wfViewPrevNext().
static Title::newFromURL | ( | $ | url | ) | [static] |
Create a new Title from URL-encoded text.
Ensures that the given title's length does not exceed the maximum.
$url | String : : the title, as might be taken from a URL |
Definition at line 160 of file Title.php.
References $t, $url, and $wgLegalTitleChars.
Referenced by MediaWiki::checkInitialQueries(), SpecialRecentchangeslinked::doMainQuery(), WhatLinksHerePage::execute(), DBConnectionError::fileCachedPage(), MergehistoryForm::MergehistoryForm(), and UndeleteForm::UndeleteForm().
static Title::newMainPage | ( | ) | [static] |
Create a new Title for the Main Page.
Definition at line 286 of file Title.php.
References $title, newFromText(), and wfMsgForContent().
Referenced by EmaillingJob::__construct(), MediaWiki::checkInitialQueries(), SkinCologneBlue::doAfterContent(), SkinCologneBlue::doBeforeContent(), SpecialResetpass::execute(), FileDeleteForm::execute(), XmlDumpWriter::homelink(), OutputPage::loginToUse(), logoText(), mainPageLink(), PreferencesForm::mainPrefsForm(), makeMainPageUrl(), OutputPage::returnToMain(), LoginForm::successfulLogin(), and Article::view().
Title::pageCond | ( | ) |
Get an associative array for selecting this title from the "page" table.
Reimplemented in FakeTitle.
Definition at line 3214 of file Title.php.
Referenced by getLatestRevID(), getTouched(), invalidateCache(), isNewPage(), and isSingleRevRedirect().
Title::prefix | ( | $ | name | ) |
Prefix some arbitrary text with the namespace or interwiki prefix of this object.
$name | String : : the text |
Definition at line 2145 of file Title.php.
References $name, and getNsText().
Referenced by getPrefixedDBkey(), getPrefixedText(), and getPrefixedURL().
static Title::purgeExpiredRestrictions | ( | ) | [static] |
Purge expired restrictions from the page_restrictions table.
Definition at line 1939 of file Title.php.
References $dbw, and wfGetDB().
Referenced by getCascadeProtectionSources(), loadRestrictions(), loadRestrictionsFromRow(), ProtectedTitlesForm::showList(), ProtectedPagesForm::showList(), and Article::updateRestrictions().
Title::purgeSquid | ( | ) |
Purge all applicable Squid URLs.
Definition at line 2534 of file Title.php.
References $u, $urls, $wgUseSquid, and getSquidURLs().
Referenced by moveToNewTitle().
Title::quickUserCan | ( | $ | action | ) |
Can $wgUser perform $action on this page? This skips potentially expensive cascading permission checks.
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.
$action | String : : action that permission needs to be checked for |
Title::resetArticleID | ( | $ | newid | ) |
This clears some fields in this object, and clears any associated keys in the "bad links" section of the link cache.
$newid | Integer : : the new Article ID |
Reimplemented in FakeTitle.
Definition at line 2109 of file Title.php.
References getPrefixedDBkey(), and LinkCache::singleton().
Referenced by moveOverExistingRedirect(), and moveToNewTitle().
Title::secureAndSplit | ( | ) | [private] |
Secure and split - main initialisation function for this object.
Assumes that mDbkeyform has been set, and is urldecoded and uses underscores, but not otherwise munged. This function removes illegal characters, splits off the interwiki and namespace prefixes, sets the other forms, and canonicalizes everything.
Definition at line 2166 of file Title.php.
References $ns, $wgCapitalLinks, $wgContLang, $wgLocalInterwiki, is(), Interwiki::isValidInterwiki(), legalChars(), IP::sanitizeIP(), setFragment(), and wfUrlencode().
Title::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.
$fragment | String : : text |
Definition at line 2386 of file Title.php.
Referenced by secureAndSplit().
Title::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 in FakeTitle.
Definition at line 3441 of file Title.php.
References $u, and getNamespace().
Title::trackbackRDF | ( | ) |
Get the trackback RDF for this page.
Reimplemented in FakeTitle.
Definition at line 3510 of file Title.php.
References $tburl, $title, $url, getFullURL(), getText(), and trackbackURL().
Title::trackbackURL | ( | ) |
Get the trackback URL for this page.
Reimplemented in FakeTitle.
Definition at line 3499 of file Title.php.
References $wgScriptExtension, $wgScriptPath, $wgServer, and getPrefixedDBkey().
Referenced by trackbackRDF().
Title::updateTitleProtection | ( | $ | create_perm, | |
$ | reason, | |||
$ | expiry | |||
) |
Update the title protection status.
$create_perm | String : : Permission required for creation | |
$reason | String : : Reason for protection | |
$expiry | String : : Expiry timestamp |
Definition at line 1409 of file Title.php.
References $dbw, $reason, $title, $wgContLang, $wgUser, Block::encodeExpiry(), getDBkey(), getNamespace(), getRestrictions(), wfGetDB(), wfMsgForContent(), and wfTimestampNow().
Title::userCan | ( | $ | action, | |
$ | doExpensiveQueries = true | |||
) |
Can $wgUser perform $action on this page?
$action | String : : action that permission needs to be checked for | |
$doExpensiveQueries | Boolean : : Set this to false to avoid doing unnecessary queries. |
Reimplemented in FakeTitle.
Definition at line 1060 of file Title.php.
References $action, $wgUser, and getUserPermissionsErrorsInternal().
Referenced by moveSubpages(), quickUserCan(), userCanCreate(), userCanEdit(), and userCanMove().
Title::userCanCreate | ( | $ | doExpensiveQueries = true |
) |
Can $wgUser create this page?
Definition at line 1482 of file Title.php.
References userCan().
Title::userCanEdit | ( | $ | doExpensiveQueries = true |
) |
Can $wgUser edit this page?
Reimplemented in FakeTitle.
Definition at line 1473 of file Title.php.
References userCan().
Title::userCanEditCssJsSubpage | ( | ) |
Title::userCanMove | ( | $ | doExpensiveQueries = true |
) |
Can $wgUser move this page?
Definition at line 1491 of file Title.php.
References userCan().
Title::userCanRead | ( | ) |
Can $wgUser read this page?
Reimplemented in FakeTitle.
Definition at line 1510 of file Title.php.
References $name, $result, $wgGroupPermissions, $wgUser, $wgWhitelistRead, getDBkey(), getNamespace(), getPrefixedText(), SpecialPage::getTitleFor(), isSpecial(), SpecialPage::resolveAliasWithSubpage(), and wfRunHooks().
Title::userIsWatching | ( | ) |
Title::$mArticleID = -1 |
Title::$mBacklinkCache = null |
Title::$mCascadeRestriction |
Title::$mCascadeSources |
Title::$mDefaultNamespace = NS_MAIN |
Title::$mFragment |
Title::$mHasCascadingRestrictions |
Title::$mNamespace = NS_MAIN |
Title::$mNotificationTimestamp = array() |
Title::$mOldRestrictions = false |
Title::$mPrefixedText |
Title::$mRedirect = null |
Title::$mRestrictions = array() |
Title::$mRestrictionsExpiry = array() |
Title::$mRestrictionsLoaded = false |
Title::$mTextform = '' |
Title::$mUserCaseDBKey |
Title::$mWatched = null |
Is $wgUser watching this page? null if unfilled, accessed through userIsWatching().
Title::$titleCache = array() [static, private] |
const Title::CACHE_MAX = 1000 |
Title::newFromText maintains a cache to avoid expensive re-normalization of commonly used titles.
On a batch operation this can become a memory leak if not bounded. After hitting this many titles reset the cache.