$(document).ready(function(){
	$("#header .corner-box.wide .teaser-box:first").addClass("first");
	$("#topmenu li:first").addClass("first");
	$("#topmenu-sub li:first").addClass("first");
	$("#logoAndLinks li:first").addClass("first");
	$("#c-2 .border-box:first").addClass("first");
	$("#c-3 .border-box:first").addClass("first");
	$("#c-2 .border-box:last").addClass("last");
	$(".boxlinks li:first-child").addClass("first");
	$("#c-3 .border-box.block-type-itemlist:last").addClass("last");
	$("#footer .footer-content-box.footer-navi ul li:first").addClass("first");
	$(".article-links li:first-child").addClass("first");
	$(".block-company li:first-child").addClass("first");
	$(".calendar_search_row:odd").addClass("odd");
	$(".calendar_search_row:even").addClass("even");
	$("#ezagenda_calendar_container table td:has(a)").addClass("haslink");
	$("#ezagenda_calendar_container2 table td:has(a)").addClass("haslink");
	$(".border-box:has(.block-left-image)").addClass("hasimage");
	$("#cal_select").click(function(){
	 var str = "Add calender opening scripts";
		alert(str);
		return false;
	});
	/**
	* right way to add first-class
	* $(".holder div:first-child").addClass("first");
	* below is the wrong way, IE messes up the abovementioned style when there are
	* html comment tags in the code
	*/
	$(".holder div").each(function(index){
		var last = (index%4 == 0) ? "first" : "";
		$(this).addClass(last);
	});

/*
	$("#searchbox form").submit(function(){

		alert('haku pois kaytosta');

		return false;

	});
*/

});

