$(function() {
    $('#cycle').cycle({ delay: -1000, speed: 1300, timeout: 7200 });
});

function loginClick () {
jPrompt( 'Please enter the administrator password', "", 'Administrator Login', function(pw) {
  if ( pw ) {
	f = document.forms['login'];
	f['opt'].value = 'login';
	f['password'].value = pw;
	f['location'].value = location.href;
	f.submit();
  }
} );
}

function logoutClick () {
	f = document.forms['login'];
	f['opt'].value = 'logout';
	f['location'].value = location.href;
	f.submit();
}

function thumbClick(picId, picTitle) {
	if ( currentPicId ) {
		document.getElementById("img" + currentPicId).className = "";
	}
	currentPicId = picId;
	if ( currentPicId != 0 ) {
		var src = "image.php?" + currentPicId + "-390-70";		// 450
		document.getElementById("bigimg").src = src; 
		document.getElementById("paintingtitle").innerHTML= picTitle;
		document.getElementById("img" + currentPicId).className = "over";
	}
}

$.alerts.overlayColor = "black";
$.alerts.overlayOpacity = 0.4;

