v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Difference between revisions of "User:Lethosor/prefixindex.js"

From Dwarf Fortress Wiki
Jump to navigation Jump to search
(Created page with "→‎Adds a tab for "Special:PrefixIndex" to navigation bar: addOnloadHook(function(){jQuery(function($){ pi={}; pi.link = $("<li>").append($("<span>")); pi.link.find('span...")
 
m
Line 2: Line 2:
 
Adds a tab for "Special:PrefixIndex" to navigation bar
 
Adds a tab for "Special:PrefixIndex" to navigation bar
 
*/
 
*/
addOnloadHook(function(){jQuery(function($){
+
addOnloadHook(function(){jQuery(function($){setTimeout(function(){
 
pi={};
 
pi={};
 
pi.link = $("<li>").append($("<span>"));
 
pi.link = $("<li>").append($("<span>"));
Line 10: Line 10:
 
$("#left-navigation #p-namespaces ul:nth(0)").append(pi.link)
 
$("#left-navigation #p-namespaces ul:nth(0)").append(pi.link)
 
return window.prefixindex=pi;
 
return window.prefixindex=pi;
})});
+
},500)})});

Revision as of 23:44, 12 May 2013

/*
Adds a tab for "Special:PrefixIndex" to navigation bar
*/
addOnloadHook(function(){jQuery(function($){setTimeout(function(){
	pi={};
	pi.link = $("<li>").append($("<span>"));
	pi.link.find('span:nth(0)').append(
		$("<a href='"+wgScript+"/Special:PrefixIndex/"+wgPageName+"' target='_blank'>").text('PrefixIndex')
	);
	$("#left-navigation #p-namespaces ul:nth(0)").append(pi.link)
	return window.prefixindex=pi;
},500)})});