Team:Wageningen UR/JS/scripts.js

From 2013.igem.org

$=jQuery.noConflict();

$('h1.firstHeading, #contentSub').remove(); $('#topmenu .menucenter li .selflink').parent().addClass('active');

$(function ($) {

   jQuery(document).ready(function ($) {

$('.sub-project li:first-child a, .sub-project li:first-child .selflink').prepend('<img src="Petri_dish.png">'); $('.sub-project li:nth-child(2) a, .sub-project li:nth-child(2) .selflink').prepend('<img src="Aspergillus-icon.png">'); $('.sub-project li:nth-child(3) a, .sub-project li:nth-child(3) .selflink').prepend('<img src="lovastatin-icon2.png">'); $('.sub-project li:nth-child(4) a, .sub-project li:nth-child(4) .selflink').prepend('<img src="Atp-icon.png">'); $('.sub-project li:nth-child(5) a, .sub-project li:nth-child(5) .selflink').prepend('<img src="Ph-icon.png">'); $('.sub-project li:nth-child(6) a, .sub-project li:nth-child(6) .selflink').prepend('<img src="cyto-icon.png">'); $('.sub-project li:nth-child(7) a, .sub-project li:nth-child(7) .selflink').prepend('<img src="chromo-icon.png">'); $('.sub-project li:nth-child(8) a, .sub-project li:nth-child(8) .selflink').prepend('<img src="morphology-icon.png">'); $('.sub-project li:nth-child(9) a, .sub-project li:nth-child(9) .selflink').prepend('<img src="applications3-icon.png">');

$('.sub-modeling li:first-child a, .sub-modeling li:first-child .selflink').prepend('<img src="flux-icon.png">'); $('.sub-modeling li:nth-child(2) a, .sub-modeling li:nth-child(2) .selflink').prepend('<img src="Database-icon.png">');

$('.sub-parts li:first-child a, .sub-parts li:first-child .selflink').prepend('<img src="Biobricks-icon.png">'); $('.sub-parts li:nth-child(2) a, .sub-parts li:nth-child(2) .selflink').prepend('<img src="Imprbiobricks-icon.png">');

$('.sub-team li:first-child a, .sub-team li:first-child .selflink').prepend('<img src="members-icon.png">'); $('.sub-team li:nth-child(2) a, .sub-team li:nth-child(2) .selflink').prepend('<img src="profile-icon.png">'); $('.sub-team li:nth-child(3) a, .sub-team li:nth-child(3) .selflink').prepend('<img src="Medals-icon.png">'); $('.sub-team li:nth-child(4) a, .sub-team li:nth-child(4) .selflink').prepend('<img src="sponsors-icon.png">');

$('.sub-safety li:first-child a, .sub-safety li:first-child .selflink').prepend('<img src="intro-icon.png">'); $('.sub-safety li:nth-child(2) a, .sub-safety li:nth-child(2) .selflink').prepend('<img src="general-safety-icon.png">'); $('.sub-safety li:nth-child(3) a, .sub-safety li:nth-child(3) .selflink').prepend('<img src="fungi-safety-icon.png">'); $('.sub-safety li:nth-child(4) a, .sub-safety li:nth-child(4) .selflink').prepend('<img src="regulations-icon.png">'); $('.sub-safety li:nth-child(5) a, .sub-safety li:nth-child(5) .selflink').prepend('<img src="suggestion-icon.png">'); $('.sub-safety li:nth-child(6) a, .sub-safety li:nth-child(6) .selflink').prepend('<img src="applications3-icon.png">');

$('.sub-human-practices li:first-child a, .sub-human-practices li:first-child .selflink').prepend('<img src="vitruvian-icon.png">'); $('.sub-human-practices li:nth-child(2) a, .sub-human-practices li:nth-child(2) .selflink').prepend('<img src="Cafe-icon.png">'); $('.sub-human-practices li:nth-child(3) a, .sub-human-practices li:nth-child(3) .selflink').prepend('<img src="Conference-icon.png">'); $('.sub-human-practices li:nth-child(4) a, .sub-human-practices li:nth-child(4) .selflink').prepend('<img src="Collaborations-icon.png">');

$('.sub-notebook li:first-child a, .sub-notebook li:first-child .selflink').prepend('<img src="protocols-icon.png">'); $('.sub-notebook li:nth-child(2) a, .sub-notebook li:nth-child(2) .selflink').prepend('<img src="protocols-icon.png">');

$('.subs .extern').css({'background-image': 'none', 'padding-right': '0'});

$("#footer-box #footer:nth-child(2) ul").clone(true, true).contents().appendTo('#footer-box #footer:first-child ul'); $("#footer-box #footer:nth-child(2)").remove();

      $(window).load(function(){
       $('#topmenu .project, ul.sub-project').hover(
           function() {
               $('ul.sub-project').toggleClass('active');
           }
       );
       $('#topmenu .modeling a, ul.sub-modeling').hover(
           function() {
               $('ul.sub-modeling').toggleClass('active');
           }
       );
       $('#topmenu .parts, ul.sub-parts').hover(
           function() {
               $('ul.sub-parts').toggleClass('active');
           }
       );
       $('#topmenu .notebook, ul.sub-notebook').hover(
           function() {
               $('ul.sub-notebook').toggleClass('active');
           }
       );
       $('#topmenu .safety, ul.sub-safety').hover(
           function() {
               $('ul.sub-safety').toggleClass('active');
           }
       );
       $('#topmenu .team, ul.sub-team').hover(
           function() {
               $('ul.sub-team').toggleClass('active');
           }
       );
       $('#topmenu .menuright, ul.sub-human-practices').hover(
           function() {
               $('ul.sub-human-practices').toggleClass('active');
           }
       );
   }); 
   });

});