Index: trunk/phase3/docs/hooks.txt |
— | — | @@ -637,8 +637,9 @@ |
638 | 638 | the link, like "§ion=$section" |
639 | 639 | $tooltip: The default tooltip. Escape with htmlspecialchars() before using. |
640 | 640 | By default, this is wrapped in the 'editsectionhint' message. |
641 | | -$result: The HTML to return, prefilled with the default plus whatever other |
| 641 | +&$result: The HTML to return, prefilled with the default plus whatever other |
642 | 642 | changes earlier hooks have made |
| 643 | +$lang: The language code to use for the link in the wfMsg* functions |
643 | 644 | |
644 | 645 | 'EditFilter': Perform checks on an edit |
645 | 646 | $editor: Edit form (see includes/EditPage.php) |
— | — | @@ -737,7 +738,8 @@ |
738 | 739 | $title: Title being linked to |
739 | 740 | $section: Section to link to |
740 | 741 | $link: Default link |
741 | | -$result: Result (alter this to override the generated links) |
| 742 | +&$result: Result (alter this to override the generated links) |
| 743 | +$lang: The language code to use for the link in the wfMsg* functions |
742 | 744 | |
743 | 745 | 'EmailConfirmed': When checking that the user's email address is "confirmed" |
744 | 746 | $user: User being checked |
Index: trunk/phase3/includes/Linker.php |
— | — | @@ -1395,7 +1395,7 @@ |
1396 | 1396 | $attribs = " title=\"$attribs\""; |
1397 | 1397 | } |
1398 | 1398 | $result = null; |
1399 | | - wfRunHooks( 'EditSectionLink', array( &$this, $nt, $section, $attribs, $link, &$result ) ); |
| 1399 | + wfRunHooks( 'EditSectionLink', array( &$this, $nt, $section, $attribs, $link, &$result, $lang ) ); |
1400 | 1400 | if ( !is_null( $result ) ) { |
1401 | 1401 | # For reverse compatibility, add the brackets *after* the hook is |
1402 | 1402 | # run, and even add them to hook-provided text. (This is the main |
— | — | @@ -1410,7 +1410,7 @@ |
1411 | 1411 | $result = wfMsgExt( 'editsection-brackets', array( 'escape', 'replaceafter', 'language' => $lang ), $link ); |
1412 | 1412 | $result = "<span class=\"editsection\">$result</span>"; |
1413 | 1413 | |
1414 | | - wfRunHooks( 'DoEditSectionLink', array( $this, $nt, $section, $tooltip, &$result , $lang) ); |
| 1414 | + wfRunHooks( 'DoEditSectionLink', array( $this, $nt, $section, $tooltip, &$result, $lang ) ); |
1415 | 1415 | return $result; |
1416 | 1416 | } |
1417 | 1417 | |