Wikipedia:WikiProject User scripts/Scripts/Get Page Name: Difference between revisions

Content deleted Content added
textContent not supported in IE
m normalize nowiki comment
Line 1:
Returns the name of the page. For example, if you were browsing the "[[foo]]" WP page, getPname() would return "foo".
 
// <pre><nowiki>
function getPname() {
z=document.getElementById("content").childNodes;
Line 16:
return document.title.substr(0, document.title.lastIndexOf(' - Wikipedia, the free'));
*/
// </nowiki></pre>
 
/*