Template:Team:Groningen/sandboxHeader

From 2010.igem.org

(Difference between revisions)
Line 27: Line 27:
<script type="text/javascript" src="http://casualconnect.net/iGEM/jquery.address-1.2.1.min.js"></script>
<script type="text/javascript" src="http://casualconnect.net/iGEM/jquery.address-1.2.1.min.js"></script>
<script type="text/javascript">
<script type="text/javascript">
 +
 +
 +
var pages = ["home", "project", "images", "modeling", "team", "contact"];
 +
function ucfirst(str) {
function ucfirst(str) {
Line 32: Line 36:
     return firstLetter.toUpperCase() + str.substr(1);
     return firstLetter.toUpperCase() + str.substr(1);
}
}
-
var pages = ["home", "project", "images", "modeling", "team", "contact"];
+
 
 +
$(document).ready(function() {
 +
 +
$("ul#topnav li").hover(function() { //Hover over event on list item
 +
$(this).css({ 'background' : '#1376c9 url(topnav_active.gif) repeat-x'}); //Add background color + image on hovered list item
 +
$(this).find("span").show(); //Show the subnav
 +
} , function() { //on hover out...
 +
$(this).css({ 'background' : 'none'}); //Ditch the background
 +
$(this).find("span").hide(); //Hide the subnav
 +
});
 +
 +
});
     $.address.change(function (event) {
     $.address.change(function (event) {

Revision as of 10:53, 20 August 2010