Template:Team:Edinburgh/Code
From 2013.igem.org
(Difference between revisions)
Hristianita (Talk | contribs) |
Hristianita (Talk | contribs) |
||
Line 295: | Line 295: | ||
if (gallery_active_id >= $(".gallery > p > a > img").length) gallery_active_id = 0; | if (gallery_active_id >= $(".gallery > p > a > img").length) gallery_active_id = 0; | ||
$(".gallery > p > a > img").css("display", "none"); | $(".gallery > p > a > img").css("display", "none"); | ||
- | $(".gallery > p > a > img")[gallery_active_id].style.display="block"; | + | if ($(".gallery > p > a > img")[gallery_active_id]) $(".gallery > p > a > img")[gallery_active_id].style.display="block"; |
} | } | ||
Revision as of 20:54, 3 October 2013