function encryptPass()
{
	public_key='888927db66341b25125db002504fe5b';
	nrmd5 = Math.round(Math.random()*100);
	pass=hex_md5(hex_md5(document.loginform.pass.value)+public_key);
	for (i=0;i<nrmd5;i++) pass=hex_md5(pass);
	
	document.loginform.pass_hash.value=pass;
	document.loginform.pass.value='';
	return true;
}

function bigimage_dialog(imgid,iwidth,iheight) 
{
	Dialog.alert(
		'<div style="width:'+iwidth+';height:'+iheight+';"><img class="bordered" src="displayimage.php?id='+imgid+'&width='+iwidth+'&height='+iheight+'"/></div>',
		{
			windowParameters: {
				className: "alphacube",
				//className: "mac_os_x",
				width: (iwidth+30),
				height: (iheight+60)
			}, 
			okLabel: "Close",
			ok: function(win) {
				win.hide();
			}
		}
	);
}

