Difference between revisions of "Template:SJTU-BioX-Shanghai/Content"
Line 23: | Line 23: | ||
$(document).ready(function () { | $(document).ready(function () { | ||
$('#toc div#toctitle + ul a').click( | $('#toc div#toctitle + ul a').click( | ||
− | function(evnt){ | + | function(evnt){ |
var a = evnt.currentTarget; | var a = evnt.currentTarget; | ||
var id = a.attributes["href"].value; | var id = a.attributes["href"].value; | ||
Line 31: | Line 31: | ||
var windowHeight = docEle.clientHeight | var windowHeight = docEle.clientHeight | ||
− | if ((pageHeight - top) > windowHeight) setTimeout ("scrollBy(0, -20)", 10); | + | if ((pageHeight - top) > windowHeight) true |
− | + | setTimeout ("scrollBy(0, -20)", 10); | |
} | } | ||
) | ) |
Revision as of 08:35, 12 September 2015