jQuery(document).ready(function() {
	// make the whole box clickable
	jQuery(".clickablecontainer").each(function(i,el){
		el = jQuery(el);
		el.css("cursor","pointer");
		el.click(function(){
			var url = el.find("a:first").attr("href");
			location.href = url;
		});
	});
	/* var carousel = jQuery('#carousel');
	carousel.jCarouselLite({
        auto: 10000,
        scroll:1,
        visible:1,
        speed:500
   }); */
	jQuery('#carousel').slides({
			preload: false,
			play: 10000,
			pause: 2500,
			slideSpeed: 500,
			hoverPause: true
		});
});

function addShareLinks(title, url){
	var parent = jQuery("#shareLinks"),
		form,
		tipLink,
		printLink;
		
	if(parent){
		// add links
		printLink = jQuery("<a href='#'>").html('<img src="/gfx/icons/print.png" alt=" " />').click(function(e) {
			window.print();
			return false;
		});
		jQuery("<dd>").append(printLink).appendTo(parent);
		// build the form
	}
}
