Index: trunk/phase3/docs/hooks.txt |
— | — | @@ -436,6 +436,10 @@ |
437 | 437 | &$siteNotice: HTML sitenotice |
438 | 438 | Alter the contents of $siteNotice to add to/alter the sitenotice/anonnotice. |
439 | 439 | |
| 440 | +'SkinTemplateOutputPageBeforeExec': Before SkinTemplate::outputPage() starts page output |
| 441 | +&$sktemplate: SkinTemplate object |
| 442 | +&$tpl: Template engine object |
| 443 | + |
440 | 444 | 'TitleMoveComplete': after moving an article (title) |
441 | 445 | $old: old title |
442 | 446 | $nt: new title |
Index: trunk/phase3/includes/SkinTemplate.php |
— | — | @@ -458,6 +458,11 @@ |
459 | 459 | $tpl->set( 'sidebar', $this->buildSidebar() ); |
460 | 460 | $tpl->set( 'nav_urls', $this->buildNavUrls() ); |
461 | 461 | |
| 462 | + // original version by hansm |
| 463 | + if( !wfRunHooks( 'SkinTemplateOutputPageBeforeExec', array( &$this, &$tpl ) ) ) { |
| 464 | + wfDebug( __METHOD__ . ': Hook SkinTemplateOutputPageBeforeExec broke outputPage execution!' ); |
| 465 | + } |
| 466 | + |
462 | 467 | // execute template |
463 | 468 | wfProfileIn( "$fname-execute" ); |
464 | 469 | $res = $tpl->execute(); |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -35,6 +35,8 @@ |
36 | 36 | * Made the PLURAL: parser function return singular on -1 per default. |
37 | 37 | * Fixed up the AjaxSearch |
38 | 38 | * (bugs 5051, 5376) Tooltips and accesskeys no longer require JavaScript |
| 39 | +* Added SkinTemplateOutputPageBeforeExec hook before SkinTemplate::outputPage() |
| 40 | + starts page output (http://lists.wikimedia.org/pipermail/wikitech-l/2007-January/028554.html) |
39 | 41 | |
40 | 42 | == Languages updated == |
41 | 43 | |