	$(document).ready(function() {

// JQUERY =================================

	$("#accordion").accordion({ header: "h3" });		
	$('#tabs').tabs();

	$("#datepicker").datepicker();

	$("#autocomplete").autocomplete({
					source: ["c++", "java", "php", "coldfusion", "javascript", "asp", "ruby", "python", "c", "scala", "groovy", "haskell", "perl"]
				});

	$("#button").button();
	$("#radioset").buttonset();


	$("#progressbar").progressbar({
				value: 37
			});

	$('#slider').slider({
					range: true,
					values: [17, 67]
				});

			// Dialog			
				$('#dialog').dialog({
					autoOpen: false,
					width: 600,
					buttons: {
						"Ok": function() { 
							$(this).dialog("close"); 
						}, 
						"Cancel": function() { 
							$(this).dialog("close"); 
						} 
					}
				});
	// Dialog Link
				$('#dialog_link').click(function(){
					$('#dialog').dialog('open');
					return false;
				});



	 $('#mycarousel').jcarousel({
        auto: 4,
        wrap: 'last'
	    });


// EXTERNAL =================================
	$('#external_links a').filter(function() {
			return this.hostname && this.hostname !== location.hostname;
		}).after(' <img src="inc/js/images/external.png" alt="external link"/>');

// EQUAL =================================
	$(function(){ $('#equalize').equalHeights(); });

// FANCYBOX =================================
	$("a.jq_fancy").fancybox({
		'titleShow'     : false
	});

	$("a.jq_fancy_gal").fancybox({
		'titleShow'     : false,
		'transitionIn'	: 'elastic',
		'transitionOut'	: 'elastic'
	});

	$("a.jq_fancy_zoom").fancybox({
		'titleShow'     : false,
		'transitionIn'	: 'none',
		'transitionOut'	: 'none'
	});

	$(".jq_fancy_ajax").fancybox({

	});

	$("a.jq_fancy_inline").fancybox({
		'titleShow'     : false,
		'width'		:	800,
		'height'		:	500
	});

	$(".jq_fancy_iframe").fancybox({
		'width'				: '75%',
		'height'			: '75%',
		'autoScale'     	: false,
		'transitionIn'		: 'none',
		'transitionOut'		: 'none',
		'type'				: 'iframe'
	});


// SLIDERS =================================
	$(".jq_trigger_container").hide(); 

	$("div.jq_trigger").toggle(function() { //Switch the "Open" and "Close" state per click
		$(this).addClass("jq_trigger_active");
		}, function () {
		$(this).removeClass("jq_trigger_active");
	});

	$("div.jq_trigger").click(function() {	//Slide up and down on click
		$(this).next(".jq_trigger_container").slideToggle();
	});

// FEEDBACK STRIP  =================================
	$(".jq_feedback_error .jq_feedback_img").click(function(){
		  $(this).parents(".jq_feedback_error").animate({ opacity: "hide" }, "slow");
	});
	$(".jq_feedback_ok .jq_feedback_img").click(function(){
		  $(this).parents(".jq_feedback_ok").animate({ opacity: "hide" }, "slow");
	});
	$(".jq_feedback_info .jq_feedback_img").click(function(){
		  $(this).parents(".jq_feedback_info").animate({ opacity: "hide" }, "slow");
	});
	$(".jq_feedback_message .jq_feedback_img").click(function(){
		  $(this).parents(".jq_feedback_message").animate({ opacity: "hide" }, "slow");
	});
	$(".jq_feedback_content .jq_feedback_img").click(function(){
		  $(this).parents(".jq_feedback_content").animate({ opacity: "hide" }, "slow");
	});
   setTimeout(function(){
		$("div.jq_feedback_action").fadeOut("slow", function () {
		$("div.jq_feedback_action").remove();
      });
	 }, 2000);

/* SHOW HIDE PODS */
    $(".jq_showhide_1").click(function () {
      $("div.jq_showhide_element_1").toggle("slow");
    });
	 $(".jq_showhide_2").click(function () {
      $("div.jq_showhide_element_2").toggle("slow");
    });
	 $(".jq_showhide_3").click(function () {
      $("div.jq_showhide_element_3").toggle("slow");
    });
	 $(".jq_showhide_4").click(function () {
      $("div.jq_showhide_element_4").toggle("slow");
    });

 $('.slideshow').cycle({
		fx: 'fade' // choose your transition type, ex: fade, scrollUp, shuffle, etc...
	});



// =================================
	}); // END OF document ready

