Team:XMU Software/js
From 2013.igem.org
YuezhenChen (Talk | contribs) |
YuezhenChen (Talk | contribs) |
||
Line 7: | Line 7: | ||
$('#safety_navi3').show(); | $('#safety_navi3').show(); | ||
$('#project_navi6').show(); | $('#project_navi6').show(); | ||
- | $('# | + | $('#outreach6').show(); |
}else{ | }else{ | ||
$('#team_navi6').hide(); | $('#team_navi6').hide(); | ||
Line 13: | Line 13: | ||
$('#safety_navi3').hide(); | $('#safety_navi3').hide(); | ||
$('#project_navi6').hide(); | $('#project_navi6').hide(); | ||
- | $('# | + | $('#outreach6').hide(); |
} | } | ||
} | } | ||
Line 26: | Line 26: | ||
}) | }) | ||
movetotop(); | movetotop(); | ||
- | $('# | + | $('#outreach6').click(function(){ |
$("#xmu_body").scrollTop(0); | $("#xmu_body").scrollTop(0); | ||
}) | }) | ||
Line 41: | Line 41: | ||
document.getElementById("team_navi1").style.background="#ffd200"; | document.getElementById("team_navi1").style.background="#ffd200"; | ||
document.getElementById("notebook_navi1").style.background="#ffd200"; | document.getElementById("notebook_navi1").style.background="#ffd200"; | ||
- | document.getElementById(" | + | document.getElementById("outreach1").style.background="#ffd200"; |
document.getElementById("project_navi1").style.background="#ffd200"; | document.getElementById("project_navi1").style.background="#ffd200"; | ||
document.getElementById("safety_navi1").style.background="#ffd200"; | document.getElementById("safety_navi1").style.background="#ffd200"; | ||
Line 48: | Line 48: | ||
document.getElementById("team_navi1").style.background="#b3d465"; | document.getElementById("team_navi1").style.background="#b3d465"; | ||
document.getElementById("notebook_navi1").style.background="#b3d465"; | document.getElementById("notebook_navi1").style.background="#b3d465"; | ||
- | document.getElementById(" | + | document.getElementById("outreach1").style.background="#b3d465"; |
document.getElementById("project_navi1").style.background="#b3d465"; | document.getElementById("project_navi1").style.background="#b3d465"; | ||
document.getElementById("safety_navi1").style.background="#b3d465"; | document.getElementById("safety_navi1").style.background="#b3d465"; | ||
Line 55: | Line 55: | ||
document.getElementById("team_navi2").style.background="#ffd200"; | document.getElementById("team_navi2").style.background="#ffd200"; | ||
document.getElementById("notebook_navi2").style.background="#ffd200"; | document.getElementById("notebook_navi2").style.background="#ffd200"; | ||
- | document.getElementById(" | + | document.getElementById("outreach2").style.background="#ffd200"; |
document.getElementById("project_navi2").style.background="#ffd200"; | document.getElementById("project_navi2").style.background="#ffd200"; | ||
document.getElementById("safety_navi2").style.background="#ffd200"; | document.getElementById("safety_navi2").style.background="#ffd200"; | ||
Line 62: | Line 62: | ||
document.getElementById("team_navi2").style.background="#b3d465"; | document.getElementById("team_navi2").style.background="#b3d465"; | ||
document.getElementById("notebook_navi2").style.background="#b3d465"; | document.getElementById("notebook_navi2").style.background="#b3d465"; | ||
- | document.getElementById(" | + | document.getElementById("outreach2").style.background="#b3d465"; |
document.getElementById("project_navi2").style.background="#b3d465"; | document.getElementById("project_navi2").style.background="#b3d465"; | ||
document.getElementById("safety_navi2").style.background="#b3d465"; | document.getElementById("safety_navi2").style.background="#b3d465"; | ||
Line 69: | Line 69: | ||
document.getElementById("team_navi3").style.background="#ffd200"; | document.getElementById("team_navi3").style.background="#ffd200"; | ||
document.getElementById("notebook_navi3").style.background="#ffd200"; | document.getElementById("notebook_navi3").style.background="#ffd200"; | ||
- | document.getElementById(" | + | document.getElementById("outreach3").style.background="#ffd200"; |
document.getElementById("project_navi3").style.background="#ffd200"; | document.getElementById("project_navi3").style.background="#ffd200"; | ||
document.getElementById("safety_navi3").style.background="#ffd200"; | document.getElementById("safety_navi3").style.background="#ffd200"; | ||
Line 76: | Line 76: | ||
document.getElementById("team_navi3").style.background="#b3d465"; | document.getElementById("team_navi3").style.background="#b3d465"; | ||
document.getElementById("notebook_navi3").style.background="#b3d465"; | document.getElementById("notebook_navi3").style.background="#b3d465"; | ||
- | document.getElementById(" | + | document.getElementById("outreach3").style.background="#b3d465"; |
document.getElementById("project_navi3").style.background="#b3d465"; | document.getElementById("project_navi3").style.background="#b3d465"; | ||
document.getElementById("safety_navi3").style.background="#b3d465"; | document.getElementById("safety_navi3").style.background="#b3d465"; | ||
Line 82: | Line 82: | ||
function navi4(){ | function navi4(){ | ||
document.getElementById("team_navi4").style.background="#ffd200"; | document.getElementById("team_navi4").style.background="#ffd200"; | ||
- | document.getElementById(" | + | document.getElementById("outreach4").style.background="#ffd200"; |
document.getElementById("project_navi4").style.background="#ffd200"; | document.getElementById("project_navi4").style.background="#ffd200"; | ||
document.getElementById("notebook_navi4").style.background="#ffd200"; | document.getElementById("notebook_navi4").style.background="#ffd200"; | ||
Line 88: | Line 88: | ||
function navi41(){ | function navi41(){ | ||
document.getElementById("team_navi4").style.background="#b3d465"; | document.getElementById("team_navi4").style.background="#b3d465"; | ||
- | document.getElementById(" | + | document.getElementById("outreach4").style.background="#b3d465"; |
document.getElementById("project_navi4").style.background="#b3d465"; | document.getElementById("project_navi4").style.background="#b3d465"; | ||
document.getElementById("notebook_navi4").style.background="#b3d465"; | document.getElementById("notebook_navi4").style.background="#b3d465"; | ||
Line 94: | Line 94: | ||
function navi5(){ | function navi5(){ | ||
document.getElementById("team_navi5").style.background="#ffd200"; | document.getElementById("team_navi5").style.background="#ffd200"; | ||
- | document.getElementById(" | + | document.getElementById("outreach5").style.background="#ffd200"; |
document.getElementById("project_navi5").style.background="#ffd200"; | document.getElementById("project_navi5").style.background="#ffd200"; | ||
document.getElementById("notebook_navi5").style.background="#ffd200"; | document.getElementById("notebook_navi5").style.background="#ffd200"; | ||
Line 100: | Line 100: | ||
function navi51(){ | function navi51(){ | ||
document.getElementById("team_navi5").style.background="#b3d465"; | document.getElementById("team_navi5").style.background="#b3d465"; | ||
- | document.getElementById(" | + | document.getElementById("outreach5").style.background="#b3d465"; |
document.getElementById("project_navi5").style.background="#b3d465"; | document.getElementById("project_navi5").style.background="#b3d465"; | ||
document.getElementById("notebook_navi5").style.background="#b3d465"; | document.getElementById("notebook_navi5").style.background="#b3d465"; | ||
Line 106: | Line 106: | ||
function navi6(){ | function navi6(){ | ||
document.getElementById("project_navi6").style.background="#ffd200"; | document.getElementById("project_navi6").style.background="#ffd200"; | ||
- | document.getElementById(" | + | document.getElementById("outreach6").style.background="#ffd200"; |
document.getElementById("team_navi6").style.background="#ffd200"; | document.getElementById("team_navi6").style.background="#ffd200"; | ||
} | } | ||
function navi61(){ | function navi61(){ | ||
document.getElementById("project_navi6").style.background="#b3d465"; | document.getElementById("project_navi6").style.background="#b3d465"; | ||
- | document.getElementById(" | + | document.getElementById("outreach6").style.background="#b3d465"; |
document.getElementById("team_navi6").style.background="#b3d465"; | document.getElementById("team_navi6").style.background="#b3d465"; | ||
} | } |
Revision as of 11:35, 23 October 2013
function movetotop(){ h = window.innerHeight-180; t = $("#xmu_body").scrollTop(); if(t > h){ $('#team_navi6').show(); $('#notebook_navi5').show(); $('#safety_navi3').show(); $('#project_navi6').show(); $('#outreach6').show(); }else{ $('#team_navi6').hide(); $('#notebook_navi5').hide(); $('#safety_navi3').hide(); $('#project_navi6').hide(); $('#outreach6').hide(); } } $(document).ready(function(e) { movetotop(); $('#team_navi6').click(function(){ $("#xmu_body").scrollTop(0); }) movetotop(); $('#notebook_navi5').click(function(){ $("#xmu_body").scrollTop(0); }) movetotop(); $('#outreach6').click(function(){ $("#xmu_body").scrollTop(0); }) movetotop(); $('#project_navi6').click(function(){ $("#xmu_body").scrollTop(0); }) movetotop(); $('#safety_navi3').click(function(){ $("#xmu_body").scrollTop(0); }) }); function navi1(){ document.getElementById("team_navi1").style.background="#ffd200"; document.getElementById("notebook_navi1").style.background="#ffd200"; document.getElementById("outreach1").style.background="#ffd200"; document.getElementById("project_navi1").style.background="#ffd200"; document.getElementById("safety_navi1").style.background="#ffd200"; } function navi11(){ document.getElementById("team_navi1").style.background="#b3d465"; document.getElementById("notebook_navi1").style.background="#b3d465"; document.getElementById("outreach1").style.background="#b3d465"; document.getElementById("project_navi1").style.background="#b3d465"; document.getElementById("safety_navi1").style.background="#b3d465"; } function navi2(){ document.getElementById("team_navi2").style.background="#ffd200"; document.getElementById("notebook_navi2").style.background="#ffd200"; document.getElementById("outreach2").style.background="#ffd200"; document.getElementById("project_navi2").style.background="#ffd200"; document.getElementById("safety_navi2").style.background="#ffd200"; } function navi21(){ document.getElementById("team_navi2").style.background="#b3d465"; document.getElementById("notebook_navi2").style.background="#b3d465"; document.getElementById("outreach2").style.background="#b3d465"; document.getElementById("project_navi2").style.background="#b3d465"; document.getElementById("safety_navi2").style.background="#b3d465"; } function navi3(){ document.getElementById("team_navi3").style.background="#ffd200"; document.getElementById("notebook_navi3").style.background="#ffd200"; document.getElementById("outreach3").style.background="#ffd200"; document.getElementById("project_navi3").style.background="#ffd200"; document.getElementById("safety_navi3").style.background="#ffd200"; } function navi31(){ document.getElementById("team_navi3").style.background="#b3d465"; document.getElementById("notebook_navi3").style.background="#b3d465"; document.getElementById("outreach3").style.background="#b3d465"; document.getElementById("project_navi3").style.background="#b3d465"; document.getElementById("safety_navi3").style.background="#b3d465"; } function navi4(){ document.getElementById("team_navi4").style.background="#ffd200"; document.getElementById("outreach4").style.background="#ffd200"; document.getElementById("project_navi4").style.background="#ffd200"; document.getElementById("notebook_navi4").style.background="#ffd200"; } function navi41(){ document.getElementById("team_navi4").style.background="#b3d465"; document.getElementById("outreach4").style.background="#b3d465"; document.getElementById("project_navi4").style.background="#b3d465"; document.getElementById("notebook_navi4").style.background="#b3d465"; } function navi5(){ document.getElementById("team_navi5").style.background="#ffd200"; document.getElementById("outreach5").style.background="#ffd200"; document.getElementById("project_navi5").style.background="#ffd200"; document.getElementById("notebook_navi5").style.background="#ffd200"; } function navi51(){ document.getElementById("team_navi5").style.background="#b3d465"; document.getElementById("outreach5").style.background="#b3d465"; document.getElementById("project_navi5").style.background="#b3d465"; document.getElementById("notebook_navi5").style.background="#b3d465"; } function navi6(){ document.getElementById("project_navi6").style.background="#ffd200"; document.getElementById("outreach6").style.background="#ffd200"; document.getElementById("team_navi6").style.background="#ffd200"; } function navi61(){ document.getElementById("project_navi6").style.background="#b3d465"; document.getElementById("outreach6").style.background="#b3d465"; document.getElementById("team_navi6").style.background="#b3d465"; }