Team:Peking/js/home.js
From 2014.igem.org
Line 9: | Line 9: | ||
$("#pabstract").stop().slideUp("1000"); | $("#pabstract").stop().slideUp("1000"); | ||
}); | }); | ||
+ | |||
+ | |||
+ | jumpupposition(); | ||
$('#jumpup').hover(function(){ | $('#jumpup').hover(function(){ | ||
$("#jumpup img").attr({"src":"https://static.igem.org/mediawiki/2014/b/bd/Peking2014wcg_jumpupchoose.png"}); | $("#jumpup img").attr({"src":"https://static.igem.org/mediawiki/2014/b/bd/Peking2014wcg_jumpupchoose.png"}); | ||
Line 46: | Line 49: | ||
$("#mid2center img").css("height",h); | $("#mid2center img").css("height",h); | ||
//alert(h); | //alert(h); | ||
+ | |||
+ | }; | ||
+ | |||
+ | function jumpupposition() | ||
+ | { | ||
+ | var right=($("#body").width()-$("#mainbody").width())/4; | ||
+ | |||
+ | $("#jumpup").attr("right","right"); | ||
+ | $("#jumpdown").attr("right","right"); | ||
+ | alert(right); | ||
}; | }; |
Revision as of 00:24, 14 October 2014
$(document).ready(function(){ mid1size(); mid2size(); $("#mid1left").mouseover(function(){ $("#pabstract").stop().slideDown("1000"); }); $("#mid1left").mouseout(function(){ $("#pabstract").stop().slideUp("1000"); });
jumpupposition();
$('#jumpup').hover(function(){ $("#jumpup img").attr({"src":""});
},function(){
$("#jumpup img").attr({"src":""});
});
$('#jumpdown').hover(function(){ $("#jumpdown img").attr({"src":""});
},function(){
$("#jumpdown img").attr({"src":""});
});
});
function mid1size()
{
var w=$("#mid1left").width(); var h=w*480/640; $("#mid1left").css("height",h); $("#mid1right").css("height",h); // alert(height);
var w=$("#mid1right").width(); $(".SliderName_2 ").css("width",w); $(".SliderName_2 ").css("height",h); $(".SliderNamePrev_2").css("height",h); $(".SliderNameNext_2").css("height",h); };
function mid2size() {
var h=$("#mid2right").height()-100; $("#mid2center img").css("height",h); //alert(h);
};
function jumpupposition() { var right=($("#body").width()-$("#mainbody").width())/4;
$("#jumpup").attr("right","right");
$("#jumpdown").attr("right","right"); alert(right);
};