Team:ETH Zurich/Templates/interactive
From 2013.igem.org
(Difference between revisions)
Line 33: | Line 33: | ||
<div id="test_bild"><img src="https://static.igem.org/mediawiki/2013/e/e7/Plate.png"></div> | <div id="test_bild"><img src="https://static.igem.org/mediawiki/2013/e/e7/Plate.png"></div> | ||
<div id="cell_holder"> | <div id="cell_holder"> | ||
- | |||
<p class="cell_selector"> | <p class="cell_selector"> | ||
SENDER CELL | SENDER CELL | ||
</p> | </p> | ||
+ | <div id="receiver_cell" class="cell_img"><img src="https://static.igem.org/mediawiki/2013/a/a7/Receiver_cell.png"></div> | ||
<p class="cell_selector"> | <p class="cell_selector"> | ||
RECEIVER CELL | RECEIVER CELL | ||
Line 48: | Line 48: | ||
$('#test_bild2').nextAll().hide(); | $('#test_bild2').nextAll().hide(); | ||
$(document).ready(function() { | $(document).ready(function() { | ||
- | + | var selector = $('.cell_selector'); | |
- | $('#test_bild2').nextAll().delay(5000).fadeIn() | + | var imgs = $('.cell_img'); |
+ | $('#test_bild2').nextAll().delay(5000).fadeIn() | ||
+ | selector.click(function() { | ||
+ | var cur = $('this'); | ||
+ | cur.siblings('div').slideUp(); | ||
+ | cur.next('div').slideDown(); | ||
+ | }); | ||
}); | }); | ||
</script> | </script> |
Revision as of 08:42, 23 August 2013
SENDER CELL
RECEIVER CELL