r10241 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r10240‎ | r10241 | r10242 >
Date:18:55, 22 July 2005
Author:avar
Status:old
Tags:
Comment:
* (bug 2774) Add three new $wgHooks to LogPage which enable extensions to add
their own logtypes, see extensions/Renameuser/SpecialRenameuser.php for an
example of this.
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/LogPage.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/LogPage.php
@@ -89,6 +89,7 @@
9090 */
9191 function validTypes() {
9292 static $types = array( '', 'block', 'protect', 'rights', 'delete', 'upload', 'move' );
 93+ wfRunHooks( 'LogPageValidTypes', array( &$types) );
9394 return $types;
9495 }
9596
@@ -128,6 +129,8 @@
129130 'upload' => 'uploadlogpage',
130131 'move' => 'movelogpage'
131132 );
 133+ wfRunHooks( 'LogPageLogName', array( &$typeText) );
 134+
132135 return str_replace( '_', ' ', wfMsg( $typeText[$type] ) );
133136 }
134137
@@ -144,6 +147,8 @@
145148 'upload' => 'uploadlogpagetext',
146149 'move' => 'movelogpagetext'
147150 );
 151+ wfRunHooks( 'LogPageLogHeader', array( &$headerText ) );
 152+
148153 return wfMsg( $headerText[$type] );
149154 }
150155
Index: trunk/phase3/RELEASE-NOTES
@@ -591,6 +591,9 @@
592592 * Fix notice on search index update due to non-array
593593 * (bug 2885) Fix fatal errors and notices in PHP 5.1.0beta3
594594 * (bug 2931) Fix additional notices on reference use in PHP 4.4.0
 595+* (bug 2774) Add three new $wgHooks to LogPage which enable extensions to add
 596+ their own logtypes, see extensions/Renameuser/SpecialRenameuser.php for an
 597+ example of this.
595598
596599
597600 === Caveats ===

Status & tagging log