$().ready(function() {
$('.colclip').sameHeights();
$('#li_login #a_login').click(function(){
if ($('#div_login_content').css('display') == 'block') {
//$('#div_login_content').css('display','none');
$('#div_login_content').hide('slow');
} else {
$('#div_login_content').show('fast');
$.post("/script/script_ajax_mdl.php", {mdl_code:"MDL_USER_LOGIN_COL"}, function(data){
if(data.length >0) {
//data = data+"Fermer";
//$('#div_login_content').css('display','block');
$('#div_login_content').html(data);
/*$('#div_login_content').animate({
width: 'show',
height: 'show',
}, 500, 'linear');
*/
}
});
}
return false;
});
if($(window).width() > 640) {
window.onscroll = function() {
if (window.pageYOffset >= 220){
$('#menu1').addClass("topfixed centered");
if ( $('#droite').height() < 500) {
$('#droite').css({position: 'fixed', 'margin-left': '675px', top: '60px'});
}
}
else {
$('#menu1').removeClass("topfixed centered");
if ( $('#droite').height() < 500) {
$('#droite').css({position: 'relative', 'margin-left':'20px','top':''});
}
}
}
}
});
function jsToggle(idtf, selectedEffect){
//get effect type from
//most effect types need no options passed by default
var options = {};
//check if it's scale, transfer, or size - they need options explicitly set
if(selectedEffect == 'scale'){ options = {percent: 0}; }
else if(selectedEffect == 'size'){ options = { to: {width: 200,height: 60} }; }
//run the effect
$("#"+idtf).toggle(selectedEffect,options,1000);
return false;
};
/* Plugin to make variable height divs equal heights */
$.fn.sameHeights = function() {
$(this).each(function(){
var tallest = 0;
/*$(this).children().children(".paragraphe").each(function(i){
if (tallest < $(this).height()) {
tallest = $(this).height();
}
});
$(this).children().children(".paragraphe").css({'height': tallest});
*/
var tallest2 = 0;
$(this).children(".col2").each(function(i){
if (tallest2 < $(this).height()) {
tallest2 = $(this).height();
}
});
$(this).children(".col2").css({'height': tallest2});
var tallest3 = 0;
$(this).children(".col3").each(function(i){
if (tallest2 < $(this).height()) {
tallest2 = $(this).height();
}
});
$(this).children(".col3").css({'height': tallest3});
});
return this;
};
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i