Template:ITB INDONESIA/dev/js
$(function() {
var url = window.location.pathname; url = url.substr(url.lastIndexOf('/'));
switch(true) { case /\/team/.test(url) : toggleBiodata();
break; case /\/synbio-seminar/.test(url) : case /\/project-socialization/.test(url) : case /\/igem-meetup/.test(url) : case /\/monthly-journal/.test(url) : enableSlideShow(); break;
}
});
function toggleBiodata () {
$(".team-pic").click(function(event) {
var id = $(event.target).parents(".team-pic").attr('id'); if(!$("." + id).hasClass("open")) { $(".open").removeClass("open").slideToggle(); $("." + id).addClass("open").slideToggle(); } else { $("." + id).removeClass("open").slideToggle(); }
}); }
function enableSlideShow() {
$(document).ready(function() { $('.pgwSlideshow').pgwSlideshow(); });
}