Difference between revisions of "MediaWiki:Common.js"
Doduco Admin (talk | contribs) (Created page with "→Any JavaScript here will be loaded for all users on every page load.: $(function() { $(window).scroll(function() { if($(this).scrollTop() != 0) { $('#backtotop').fa...") |
Doduco Admin (talk | contribs) |
||
(3 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | |||
$(function() { | $(function() { | ||
$(window).scroll(function() { | $(window).scroll(function() { | ||
Line 13: | Line 12: | ||
}); | }); | ||
}); | }); | ||
+ | $(function(){ | ||
+ | $('#wpLicense option').each(function(){ | ||
+ | if($(this).val() != ''){ $(this).attr('selected', true);} | ||
+ | }) | ||
+ | }) |
Latest revision as of 14:59, 8 May 2014
$(function() { $(window).scroll(function() { if($(this).scrollTop() != 0) { $('#backtotop').fadeIn(); } else { $('#backtotop').fadeOut(); } }); $('#backtotop').click(function() { $('body,html').animate({scrollTop:0},800); }); }); $(function(){ $('#wpLicense option').each(function(){ if($(this).val() != ''){ $(this).attr('selected', true);} }) })