Team:Tsinghua/writenav
From 2010.igem.org
(Difference between revisions)
Line 20: | Line 20: | ||
if(k<subno.length) | if(k<subno.length) | ||
{ | { | ||
- | |||
if(j==subno[k]) | if(j==subno[k]) | ||
{ | { | ||
Line 44: | Line 43: | ||
animate = function() | animate = function() | ||
{ | { | ||
- | navRoot =document.getElementById("subnav"); | + | navRoot = document.getElementById("subnav"); |
+ | k = 0; j = 0; | ||
for (i=0; i<navRoot.childNodes.length; i++) | for (i=0; i<navRoot.childNodes.length; i++) | ||
{ | { | ||
Line 50: | Line 50: | ||
if(node.nodeName=="LI") | if(node.nodeName=="LI") | ||
{ | { | ||
+ | if(subno!=null) | ||
+ | { | ||
+ | if(subno.length>k) | ||
+ | { | ||
+ | if(j==subno[k]) | ||
+ | { | ||
+ | tarsize=8; | ||
+ | k++; | ||
+ | } | ||
+ | else | ||
+ | { | ||
+ | tarsize=11; | ||
+ | } | ||
+ | } | ||
+ | else | ||
+ | { | ||
+ | tarsize=11; | ||
+ | } | ||
+ | } | ||
if(inisize<=tarsize) | if(inisize<=tarsize) | ||
{ | { |
Revision as of 15:36, 13 October 2010