Forum:What is the Magic Word/Template/Variable/Whatever That Displays as Your Username?

Title says it all.

ROADS! Roads! (Don't forget it!) 20:13, September 16, 2011 (UTC)


 * , or ZamorakO o ( talk ) 20:35, September 16, 2011 (UTC)


 * Thanks.


 * ROADS! Roads! (Don't forget it!) 20:44, September 16, 2011 (UTC)


 * Didn't work. When I tried it, it came out like a template.


 * ROADS! Roads! (Don't forget it!) 20:46, September 16, 2011 (UTC)


 * There is a magic word to display the user name of the last person to edit the page . However, to display the user name of the person viewing the page, you need to add some code to the MediaWiki:Common.js on the wiki where you want it to work. Wookiepedia uses the following code in MediaWiki:Functions.js:

/*   Replaces  with the name of the user browsing the page. Requires copying Template:USERNAME. function substUsername { $('.insertusername').html(wgUserName); }
 * And the following template: Template:USERNAME --Gardimuer { ʈalk } 22:28, September 16, 2011 (UTC)