From 39129dc6f80c4b1ee9cff617ffa32b7d3485e221 Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Fri, 29 Feb 2008 01:10:52 +0000 Subject: [PATCH] * (bug 13031) Add links to usepages in e-mail form --- RELEASE-NOTES | 1 + includes/SpecialEmailuser.php | 11 +++++++---- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 6019ed220f..ddf2f8f511 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -59,6 +59,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN to allow functionality on not-quite-right usernames * (bug 12575) Prevent duplicate patrol log entries from being created * (bug 13174) __HIDDENCAT__ now applies only to category pages +* (bug 13031) Add links to user pages in e-mail form === API changes in 1.13 === diff --git a/includes/SpecialEmailuser.php b/includes/SpecialEmailuser.php index 7de89dce0b..e9e1144820 100644 --- a/includes/SpecialEmailuser.php +++ b/includes/SpecialEmailuser.php @@ -92,6 +92,7 @@ class EmailUserForm { function showForm() { global $wgOut, $wgUser; + $skin = $wgUser->getSkin(); $wgOut->setPagetitle( wfMsg( "emailpage" ) ); $wgOut->addWikiMsg( "emailpagetext" ); @@ -101,9 +102,11 @@ class EmailUserForm { } $emf = wfMsg( "emailfrom" ); - $sender = $wgUser->getName(); + $senderLink = $skin->makeLinkObj( + $wgUser->getUserPage(), htmlspecialchars( $wgUser->getName() ) ); $emt = wfMsg( "emailto" ); - $rcpt = $this->target->getName(); + $recipientLink = $skin->makeLinkObj( + $this->target->getUserPage(), htmlspecialchars( $this->target->getName() ) ); $emr = wfMsg( "emailsubject" ); $emm = wfMsg( "emailmessage" ); $ems = wfMsg( "emailsend" ); @@ -119,10 +122,10 @@ class EmailUserForm {
- + - +
{$emf}:" . htmlspecialchars( $sender ) . "{$senderLink}
{$emt}:" . htmlspecialchars( $rcpt ) . "{$recipientLink}
{$emr}: -- 2.20.1