<!-- Original:  Jonathan Feaster (http://www.archreality.com/) -->

<!-- Web Site:  http://www.archreality.com/jcap/ -->

<!-- Based on: Gimpy CAPTCHA Project at Carnegie Mellon University (http://www.captcha.net/) -->

<!-- Begin

function cimg(){
var imgdir = "/scripts/cap/cimg/"; //identify directory where captcha images are located
//anum = (Math.floor(Math.random()*191))+1;
imgid = parseInt(JCapAnum);
//cword = JCapWord;
/*["" ,"", "",];*/

document.write('<img src="'+imgdir+imgid+'.jpg" width=290 height=80 border=0 alt="">');
}

function jcap(){

var uword = hex_md5(document.getElementById('uword').value);
//document.getElementById('uword').value = hex_md5("toto");
//if (uword==cword[anum-1]) {
if (uword==JCapWord) {
return true;
}

else {
if(CaptchaAlertMessage){alert(CaptchaAlertMessage);}
else{alert("[CaptchaAlertMessage]");}
document.getElementById('uword').focus(); 
return false;
}
}

//  End -->