Manual:Hooks/OutputPageCheckLastModified
From Linux Web Expert
OutputPageCheckLastModified | |
---|---|
<translate> Available from <tvar name=1><translate> version <tvar </tvar></translate> When checking if the page has been modified since the last visit | |
<translate> Define function:</translate> | public static function onOutputPageCheckLastModified( &$modifiedTimes, $out ) { ... }
|
<translate> Attach hook:</translate> | <translate> In <tvar name=1>extension.json</tvar>:</translate>
{
"Hooks": {
"OutputPageCheckLastModified": "MediaWiki\\Extension\\MyExtension\\Hooks::onOutputPageCheckLastModified"
}
}
|
<translate> Called from:</translate> | <translate> File(s):</translate> Output/OutputPage.php |
<translate> Interface:</translate> | OutputPageCheckLastModifiedHook.php |
<translate> For more information about attaching hooks, see <tvar name=1>Manual:Hooks </tvar>.</translate>
<translate> For examples of extensions using this hook, see <tvar name=cat>Category:OutputPageCheckLastModified extensions</tvar>.</translate>
Details
- &$modifiedTimes: array of timestamps, the following keys are set:
- page: page's timestamp
- user: user's timestamp
- epoch: $wgCacheEpoch
- $out: OutputPage object