Template:Team:Groningen/sandboxHeader
From 2010.igem.org
(Difference between revisions)
Joelkuiper (Talk | contribs) |
Joelkuiper (Talk | contribs) |
||
Line 38: | Line 38: | ||
$(document).ready(function() { | $(document).ready(function() { | ||
- | + | rewriteLinks($("#tab_nav")); | |
- | $("ul#topnav li").hover(function() { | + | $("ul#topnav li").hover(function() { |
- | $(this).css({ 'background' : '#1376c9 url(http://casualconnect.net/iGEM/topnav_active.gif) repeat-x'}); | + | $(this).css({ 'background' : '#1376c9 url(http://casualconnect.net/iGEM/topnav_active.gif) repeat-x'}); |
- | $(this).find("span").show(); | + | $(this).find("span").show(); |
} , function() { //on hover out... | } , function() { //on hover out... | ||
- | $(this).css({ 'background' : 'none'}); | + | $(this).css({ 'background' : 'none'}); |
- | $(this).find("span").hide(); | + | $(this).find("span").hide(); |
}); | }); | ||
Line 72: | Line 72: | ||
} | } | ||
}); | }); | ||
+ | function rewriteLinks(elem) { | ||
+ | $("a",elem).each(function() { | ||
+ | var txt = $(this).text(); | ||
+ | var url = this.href; | ||
+ | |||
+ | if(this.hash) | ||
+ | this.href = this.hash; | ||
+ | else if(txt != "edit") | ||
+ | this.href = this.href.replace("https://2010.igem.org/Team:TU_Delft/", "#page="); | ||
+ | }); | ||
+ | } | ||
</script> | </script> | ||
Line 87: | Line 98: | ||
<div id="tab_nav"> | <div id="tab_nav"> | ||
<ul id="topnav"> | <ul id="topnav"> | ||
- | <li><a href=" | + | <li><a href="https://2010.igem.org/Team:Groningen/home">Home</a></li> |
<li> | <li> | ||
- | <a href="/project">Project</a> | + | <a href="https://2010.igem.org/Team:Groningen/project">Project</a> |
<span> | <span> | ||
<a href="#">Biofilm</a> | | <a href="#">Biofilm</a> | | ||
Line 101: | Line 112: | ||
<li> | <li> | ||
- | <a href=" | + | <a href="https://2010.igem.org/Team:Groningen/human">Human</a> |
<span> | <span> | ||
<a href="#">Image of Science</a> | | <a href="#">Image of Science</a> | | ||
Line 110: | Line 121: | ||
</li> | </li> | ||
<li> | <li> | ||
- | <a href=" | + | <a href="https://2010.igem.org/Team:Groningen/modeling">Modelling</a> |
<span> | <span> | ||
<a href="#">Biofilm dynamics</a> | | <a href="#">Biofilm dynamics</a> | | ||
Line 117: | Line 128: | ||
</span> | </span> | ||
</li> | </li> | ||
- | <li><a href=" | + | <li><a href="https://2010.igem.org/Team:Groningen/team">Team</a></li> |
- | <li><a href=" | + | <li><a href="https://2010.igem.org/Team:Groningen/contact">Contact</a></li> |
</ul> | </ul> | ||
</div> | </div> |
Revision as of 10:57, 20 August 2010