// Add event function
function addEvent(elm, evType, fn, useCapture) {
	if(elm.addEventListener) {
		elm.addEventListener(evType, fn, useCapture);
		return true;
		}
	else if (elm.attachEvent) {
		var r = elm.attachEvent('on' + evType, fn);
		return r;
		}
	else {
		elm['on' + evType] = fn;
		}
	}

// Open / Close help panel (jQuery)
$(document).ready(function(){
	$(".helpButton").click(function() {
		$("#content").addClass("helpPanel")
		$('#helpPanel').show('slow')
		return false;
	});

	$("#helpPanelTitle").click(function() {
		$('#helpPanel').hide('slow');
		$("#content").removeClass("helpPanel")
		return false;		
	});		


	// Lightbox plugin
	$('#smallPhotos a').lightBox({
		imageLoading: '/js/jQuery/lightbox/images/lightbox-ico-loading.gif',
		imageBtnClose: '/js/jQuery/lightbox/images/lightbox-btn-close.gif',
		imageBtnPrev: '/js/jQuery/lightbox/images/lightbox-btn-prev.gif',
		imageBtnNext: '/js/jQuery/lightbox/images/lightbox-btn-next.gif'

	});

							   


});




