Difference between revisions of "Template:China Tongji Head"

Line 204: Line 204:
 
// $('#navCollaboration').click(function(){$('html,body').animate({scrollTop: $('#Collaboration').offset().top-78}, 800);});
 
// $('#navCollaboration').click(function(){$('html,body').animate({scrollTop: $('#Collaboration').offset().top-78}, 800);});
 
// $('#navQuestionare').click(function(){$('html,body').animate({scrollTop: $('#Questionare').offset().top-78}, 800);});
 
// $('#navQuestionare').click(function(){$('html,body').animate({scrollTop: $('#Questionare').offset().top-78}, 800);});
 +
 +
//当前位置指示
 +
if(location.href.indexOf("Project")>0){
 +
document.getElementById("divProject").style.borderBottom = "4px solid #F0F";
 +
}else if(location.href.indexOf("Notebook")>0){
 +
document.getElementById("divNotebook").style.borderBottom = "4px solid #F0F";
 +
}else if(location.href.indexOf("Achivement")>0){
 +
document.getElementById("divAchivement").style.borderBottom = "4px solid #F0F";
 +
}else if(location.href.indexOf("Team")>0){
 +
document.getElementById("divTeam").style.borderBottom = "4px solid #F0F";
 +
}else if(location.href.indexOf("Outreach")>0){
 +
document.getElementById("divOutreach").style.borderBottom = "4px solid #F0F";
 +
}else if(location.href.indexOf("Safety")>0){
 +
document.getElementById("divSafety").style.borderBottom = "4px solid #F0F";
 +
}else{
 +
document.getElementById("divHome").style.borderBottom = "4px solid #F0F";
 +
}
 
});
 
});
 
</script>
 
</script>
 
</body>
 
</body>
 
</html>
 
</html>

Revision as of 11:42, 14 September 2015