Template:Team:BGU Israel/javascript.js
From 2014.igem.org
Line 75: | Line 75: | ||
break; | break; | ||
+ | |||
+ | } | ||
+ | } | ||
+ | function change_pic_intelligent() { | ||
+ | img_count=(img_count+1)%9; | ||
+ | var figure1 = document.getElementById("figure1"); | ||
+ | switch(img_count) { | ||
+ | case 0: | ||
+ | |||
+ | |||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/f/fe/BGU14PTP-1.png"; | ||
+ | break; | ||
+ | case 1: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/2/2c/BGU14PTP-2.png"; | ||
+ | break; | ||
+ | case 2: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/0/07/BGU14PTP-3.png"; | ||
+ | break; | ||
+ | case 3: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/e/e4/BGU14PTP-4.png"; | ||
+ | break; | ||
+ | case 4: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/f/f4/BGU14PTP-5.png"; | ||
+ | break; | ||
+ | case 5: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/0/08/BGU14PTP-6.png"; | ||
+ | break; | ||
+ | case 6: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/a/af/BGU14PTP-7.png"; | ||
+ | break; | ||
+ | case 7: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/1/17/BGU14PTP-8.png"; | ||
+ | break; | ||
+ | case 8: | ||
+ | figure1.src = "https://static.igem.org/mediawiki/2014/c/c5/BGU14PTP-9.png"; | ||
+ | break; | ||
} | } | ||
} | } |
Revision as of 09:41, 13 October 2014
var img_count=0;
function goToByScroll(id) { $('html,body').animate({ scrollTop: $("#" + id).offset().top }, 'slow'); }
function change_pic() { img_count=(img_count+1)%7; var figure1 = document.getElementById("figure1"); switch(img_count) {
case 0:
figure1.src = ""; break; case 1: figure1.src = ""; break;
case 2:
figure1.src = ""; break;
case 3:
figure1.src = ""; break;
case 4:
figure1.src = ""; break;
case 5:
figure1.src = ""; break;
case 6:
figure1.src = ""; break;
} } function change_pic_artificial() { img_count=(img_count+1)%5; var figure1 = document.getElementById("figure1"); switch(img_count) {
case 0:
figure1.src = ""; break; case 1: figure1.src = ""; break;
case 2:
figure1.src = ""; break;
case 3:
figure1.src = ""; break;
case 4:
figure1.src = ""; break;
}
}
function change_pic_hormone() {
img_count=(img_count+1)%4;
var figure1 = document.getElementById("figure1");
switch(img_count) {
case 0:
figure1.src = ""; break; case 1: figure1.src = ""; break;
case 2:
figure1.src = ""; break;
case 3:
figure1.src = ""; break;
}
}
function change_pic_intelligent() {
img_count=(img_count+1)%9;
var figure1 = document.getElementById("figure1");
switch(img_count) {
case 0:
figure1.src = ""; break; case 1: figure1.src = ""; break;
case 2:
figure1.src = ""; break;
case 3:
figure1.src = ""; break;
case 4:
figure1.src = ""; break;
case 5:
figure1.src = ""; break;
case 6:
figure1.src = ""; break;
case 7:
figure1.src = ""; break;
case 8:
figure1.src = ""; break;
} }