Wikipedia:WikiProject User scripts/Scripts/Get Page Name: Difference between revisions
Content deleted Content added
Jitse Niesen (talk | contribs) m normalize nowiki comment |
No edit summary |
||
(6 intermediate revisions by 5 users not shown) | |||
Line 1:
/*<pre>*/
/*Returns the name of the page. For example, if you were browsing the "[[foo]]" WP page, getPname() would return "foo".*/
function getPname() {
return mw.config.get('wgPageName').replace(/_/g, ' ');
}
▲[[Category:Wikipedia tools]]
|