jQuery(function(){
			jQuery('.sf-menu').superfish({
			
            animation:   {opacity:'show',height:'show'},  // fade-in and slide-down animation 
            
            autoArrows:  false,                           // disable generation of arrow mark-up 
            dropShadows: false                            // disable drop shadows      
			});
		});
		
jQuery(document).ready(function() {
			jQuery('.slideshow').after('<div id="nav">')
			jQuery(".loader  img").css("display", "none");	
	 		jQuery("a[rel^='prettyPhoto'], a[rel^='lightbox']").prettyPhoto({
			"theme": 'light_square' 																
	});
	  });
	  


jQuery(window).load(function() { //fades in image and hides loading image
	jQuery(".loader").css("background", "none");
    jQuery(".loader  img").fadeIn("fast");
});	

jQuery('h4.tog').click(function () {
	jQuery(this).next('div.togcont').toggle(300);
	});
	
	jQuery('h4.tog').toggle(
	function () { jQuery(this).addClass('bounce'); },
	function () { jQuery(this).removeClass('bounce');; }
	);
	
function ajaxContactWidget(theForm) {
		var $ = jQuery;
	
       

        var formData = $(theForm).serialize(),
			note = $(theForm).prev('.NoteWidget');
	
        $.ajax({
            type: "POST",
            url: "http://oasiscentre.com/content/themes/prosto/functions/prosto-contactsendwidget.php",
            data: formData,
            success: function(response) {
				if (response === 'success') {
					
					$(theForm).animate({opacity: 0},'fast');
				
					note.html('Your message has been sent. Thank you!').slideDown('fast');
                        
					setTimeout(function() {
						
						note.html('').slideUp('fast');
						$(theForm).find("input[type=text], textarea").val('');
						$(theForm).find(".prosto_button").removeAttr('disabled');	
						$(theForm).find(".prosto_button span").html("Send");
                       
						$(theForm).animate({opacity: 100},'fast');						
						},3000);
						c = 'success';
				} else {
					
					$(theForm).animate({opacity: 0},'fast');
				
					note.html(response).slideDown('fast');
					
					}
				
            }
        });

        return false;
    }
