823 B
823 B
- Since: 3.1
- Description: Hook allows to forcibly change the revision ID as in case of the
Factboxwhen building the content. - Reference class:
RevisionGuard.php
If you do alter a revision, please log the event and make it visible to a user (or administrator) that it was changed.
Signature
use MediaWiki\MediaWikiServices;
MediaWikiServices::getInstance()->getHookContainer()->register( 'SMW::RevisionGuard::ChangeRevisionID', function( $title, &$latestRevID ) {
// Set a revision ID
// $latestRevID = 42;
} );
See also
- See the
SemanticApprovedRevsextension for how to use the hook