$(function() {
	/* Call the slider on the home page with options*/
	$('#slider').anythingSlider({
		startPanel : 0,
		resizeContents : false,
		width : 645,
		height : 250,
		autoPlay : true,
		buildArrows : false,
		buildStartStop : false,
		buildNavigation : false,
		delay : 9000

	});

	/*Sets the height of the three columns on the home page*/
	var upcoming_eventsh = $('#upcoming_events').height();
	var featured_storeh = $('#featured_store').height();
	var mall_dirh = $('#mall_dir').height();

	if(upcoming_eventsh > featured_storeh && upcoming_eventsh > mall_dirh) {
		$('#featured_store').height(upcoming_eventsh);
		$('#mall_dir').height(upcoming_eventsh);
	}

	if(featured_storeh > upcoming_eventsh && featured_storeh > mall_dirh) {
		$('#mall_dir').height(featured_storeh);
		$('#upcoming_events').height(featured_storeh);
	}

	if(mall_dirh > upcoming_eventsh && mall_dirh > featured_storeh) {
		$('#upcoming_events').height(mall_dirh);
		$('#featured_store').height(mall_dirh);
	}

	/* call the Whats-New slider*/
	$(".newsticker-jcarousellite").jCarouselLite({
		vertical : true,
		visible : 1,
		auto : 3500,
		speed : 1000
	});

$('#directory_dropdown_select').change(function() {
		seoname = $(this).val();
		window.location = base_url + "view/shopping/" + seoname;

	});
	$('img[usemap]').maphilight({
		fillColor : 'FFD700',
		stroke : false

	});
    if (window.cid!=null)
    {
    	a = parseInt(cid);
    }
    else{
    	a=0;
    	
    }		
	$("#accordion").accordion({
		collapsible : true,
		autoHeight : false,
		active: a 

	});

	

});

