<!--
$(document).ready(function() {  
    $('#main-menu div.sub0 a').mouseenter(function() {
        var parentDiv = $(this).parent().get(0).id;
        var parentBlock = $(this).parent().parent().get(0).id;
        $('#'+parentBlock+' .sub1:not(#'+parentDiv+' .sub1)').hide();
        //$('#'+parentDiv+' .sub1').slideToggle(300);
        $('#'+parentDiv+' .sub1').show();
        return false;
        
    });

    $('#main-menu div.sub0').mouseleave(function() {
        var parentDiv = $(this).get(0).id;
        var parentBlock = $(this).parent().get(0).id;
        $('#'+parentBlock+' .sub1').hide();
        return false;
    });
    
    $('.product-box-micro').mouseenter(function() {
        var parentDiv = $(this).get(0).id;
        $('#'+parentDiv+' .hideInfo').slideDown(300);
        return false;
    });
    
    $('.product-box-micro').mouseleave(function() {
        var parentDiv = $(this).get(0).id;
        $('#'+parentDiv+' .hideInfo').slideUp(300);
        return false;
    });
    
    $('a.question').click(function() {
        var parentDiv = $(this).parent().parent().get(0).id;
        $('div.result .reply').css('display','none');
        $('#'+parentDiv+' .reply').fadeIn(500);
        $.scrollTo('#'+parentDiv, 500, {axis:'y'});
        return false;
    });
    
    $('a.opener').click(function() {
        var parentDiv = $(this).parent().parent().get(0).id;
        $('#'+parentDiv+' .hideInfo').slideToggle(500);
        return false;
    });
    
    $('a.postOpener').click(function() {
        var element = $(this).get(0).id;
        $('#'+element+'Form').slideToggle(500);
        $('#'+element).hide();
        return false;
    });
    
    $('.toTop').click(function() {
        $.scrollTo('#header', 500, {axis:'y'});
        return false;
    });
    
    $("a.floatBox").fancybox({ 
        'hideOnContentClick': false,
        'titleShow'		: false,
    		'transitionIn'	: 'elastic',
    		'transitionOut'	: 'fade'
    });
    
    $("a.imgPreview").fancybox({ 
        'hideOnContentClick': false,
        'titleShow'		   : true,
        'titlePosition'	 : 'over',
    		'transitionIn'	 : 'elastic',
    		'transitionOut'	 : 'fade',
    		'padding'        : 1,
			  'type'           : 'image'
    });
    
});

function showBillboard(id) {
    $(document).ready(function() {
        $("#"+id).trigger("click");
        setTimeout($.fancybox.close,4000); 
    });
}

function showAddressForm(id) {
    elementId = document.getElementById(id);
    //alert (elementId.options[elementId.selectedIndex].value);
    if(elementId.options[elementId.selectedIndex].value == 'other') {
        $('#'+id+'Other').slideDown(500);
    }
    else {
        $('#'+id+'Other').slideUp(500);
    }
}

function copyBillingData(id) {
    elementId = document.getElementById(id);
    elementId.nameDelivery.value = elementId.name.value+' '+elementId.surname.value;
    elementId.firmDelivery.value = elementId.firm.value;
    elementId.addressDelivery.value = elementId.address.value;
    elementId.zipDelivery.value = elementId.zip.value;
    elementId.cityDelivery.value = elementId.city.value;
}
-->
