$(function() {
var $box = $("div.menù_box > div.box");
var $bandiera1 = "true";
$box.bind("click",function () { //click su box
if($bandiera1=="true"){
var $questobox = $(this);
$questobox.next("div.tendina").fadeIn("slow");
$bandiera1 = "false";
$("div.img_sfondo").css("opacity","0.5");
$questobox.attr("class","box_evi");
var $left_box = $questobox.css("left");
var $top_box = $questobox.css("top");
$questobox.animate({
"left" : "280px",
"top" : "214px"
},"slow");
}
$("div.tendina > img.img_exit").bind("click",function () { //click su x-exit
$questobox.next("div.tendina").fadeOut("slow");
$bandiera1 = "true";
$("div.img_sfondo").css("opacity","1");
$questobox.attr("class","box");
$questobox.animate({
"left" : $left_box,
"top" : $top_box
},"slow");
});
});
});