var Ovr2='';if(typeof document.compatMode!='undefined'&&document.compatMode!='BackCompat'){sec_t1_DOCtp="_top:expression(document.documentElement.scrollTop+document.documentElement.clientHeight-this.clientHeight);_left:expression(document.documentElement.scrollLeft + document.documentElement.clientWidth - offsetWidth);}";}else{sec_t1_DOCtp="_top:expression(document.body.scrollTop+document.body.clientHeight-this.clientHeight);_left:expression(document.body.scrollLeft + document.body.clientWidth - offsetWidth);}";}if(typeof document.compatMode!='undefined'&&document.compatMode!='BackCompat'){sec_t1_DOCtp2="_top:expression(document.documentElement.scrollTop-20+document.documentElement.clientHeight-this.clientHeight);}";}else{sec_t1_DOCtp2="_top:expression(document.body.scrollTop-20+document.body.clientHeight-this.clientHeight);}";}var sec_bgf0=(window.location.protocol.toLowerCase()=="https:")? "https://www.monarchtrophy.com/images/lock_bg.gif" : "http://www.monarchtrophy.com/images/lock_bg.gif";
var sec_tl_bodyCSS='* html {background:url('+sec_bgf0+') fixed;background-repeat: repeat;background-position: right bottom;}';var sec_tl_fixedCSS='#sec_tl_fixed{position:fixed;';var sec_tl_fixedCSS=sec_tl_fixedCSS+'_position:absolute;';var sec_tl_fixedCSS=sec_tl_fixedCSS+'bottom:0px;';var sec_tl_fixedCSS=sec_tl_fixedCSS+'right:0px;';var sec_tl_fixedCSS=sec_tl_fixedCSS+'clip:rect(0 100 85 0);';var sec_tl_fixedCSS=sec_tl_fixedCSS+sec_t1_DOCtp;var sec_tl_popCSS='#sec_tl_pop {background-color: transparent;';var sec_tl_popCSS=sec_tl_popCSS+'position:fixed;';var sec_tl_popCSS=sec_tl_popCSS+'_position:absolute;';var sec_tl_popCSS=sec_tl_popCSS+'height:194px;';var sec_tl_popCSS=sec_tl_popCSS+'width: 244px;';var sec_tl_popCSS=sec_tl_popCSS+'right: 120px;';var sec_tl_popCSS=sec_tl_popCSS+'bottom: 20px;';var sec_tl_popCSS=sec_tl_popCSS+'overflow: hidden;';var sec_tl_popCSS=sec_tl_popCSS+'visibility: hidden;';var sec_tl_popCSS=sec_tl_popCSS+'z-index: 100;';var sec_tl_popCSS=sec_tl_popCSS+sec_t1_DOCtp2;document.write('<style type="text/css">'+sec_tl_bodyCSS+sec_tl_fixedCSS+sec_tl_popCSS+'</style>');function sec_tl_bigPopup(url){newwindow=window.open(url,'name','WIDTH=450,HEIGHT=500,FRAMEBORDER=0,MARGINWIDTH=0,MARGINHEIGHT=0,SCROLLING=no,allowtransparency=true');if(window.focus){newwindow.focus()}return false;}function sec_tl_toggleMiniPOPUP_hide(){var cred_id='sec_tl_pop';var NNtype='hidden';var IEtype='hidden';var WC3type='hidden';if(document.getElementById){eval("document.getElementById(cred_id).style.visibility=\""+WC3type+"\"");}else{if(document.layers){document.layers[cred_id].visibility=NNtype;}else{if(document.all){eval("document.all."+cred_id+".style.visibility=\""+IEtype+"\"");}}}}function sec_tl_toggleMiniPOPUP_show(){cred_id='sec_tl_pop';var NNtype='show';var IEtype='visible';var WC3type='visible';if(document.getElementById){eval("document.getElementById(cred_id).style.visibility=\""+WC3type+"\"");}else{if(document.layers){document.layers[cred_id].visibility=NNtype;}else{if(document.all){eval("document.all."+cred_id+".style.visibility=\""+IEtype+"\"");}}}}function ShowSecure(sec_tl_theLogo,sec_tl_LogoType,LogoPosition){var sec_tl_myLocation=location.host;if(window.location.protocol.toLowerCase()=="https:"){var sec_tl_miniBaseURL='https://www.monarchtrophy.com/_private/secure.htm';var sec_tl_bigBaseURL='https://www.monarchtrophy.com/_private/secure.htm';}else{var sec_tl_miniBaseURL='http://www.monarchtrophy.com/_private/secure.htm';var sec_tl_bigBaseURL='http://www.monarchtrophy.com/_private/secure.htm';};document.write('<div id="sec_tl_pop">');document.write('<IFRAME src="'+sec_tl_miniBaseURL+'" WIDTH=244 HEIGHT=194 FRAMEBORDER=0 MARGINWIDTH=0 MARGINHEIGHT=0 SCROLLING=no allowtransparency=true></IFRAME>');document.write('</div>');document.write('<div id="sec_tl_fixed">');document.write('<img src='+sec_tl_theLogo+' alt="Secure Information" border="0" onMouseOver="Ovr=setTimeout(\'sec_tl_toggleMiniPOPUP_show()\',1000);clearTimeout(Ovr2)" onMouseOut="Ovr2=setTimeout(\'sec_tl_toggleMiniPOPUP_hide()\',1000);clearTimeout(Ovr)"</a>');document.write('</div>');}
function getCookie(Name){ 
var re=new RegExp(Name+"=[^;]+", "i"); //construct RE to search for target name/value pair
if (document.cookie.match(re)) //if cookie found
return document.cookie.match(re)[0].split("=")[1] //return its value
return ""
}

function setCookie(name, value, days){
var expireDate = new Date()
//set "expstring" to either future or past date, to set or delete cookie, respectively
var expstring=expireDate.setDate(expireDate.getDate()+parseInt(days))
document.cookie = name+"="+value+"; expires="+expireDate.toGMTString()+"; path=/";
}

function RFormName(formid){ //Main remember form values object
this.formref=document.getElementById(formid)? document.getElementById(formid) : document.forms[formid]
this.cookiename=formid
this.persistdays=180 //days to persist form values
this.fields=new Array()
this.cookiestr=""
var forminstance=this
RFormName.dotask(this.formref, function(){forminstance.savevalues()}, "submit") //save form values onsubmit
RFormName.dotask(window, function(){forminstance.recallvalues()}, "load") //populate form with saved values onload (body)
}

RFormName.prototype.getfield=function(attr){ //get form field based on its ID or name attribute
var fieldref=document.getElementById(attr)? document.getElementById(attr) : this.formref[attr]
return fieldref
}

RFormName.prototype.persistfields=function(){ //get form fields to persist values for
for (var i=0; i<arguments.length; i++){
this.fields[i]=this.getfield(arguments[i])
this.fields[i].fname=arguments[i] //store name or id of field in custom property
}
}

RFormName.prototype.savevalues=function(){ //get form values and store in cookie
for (var i=0; i<this.fields.length; i++){
if (this.fields[i].type=="text")
this.cookiestr+=this.fields[i].fname+":"+escape(this.fields[i].value)+"#"
}
if (typeof this.togglebox!="undefined"){ //if "remember values checkbox" is defined
this.persistdays=(this.togglebox.checked)? this.persistdays : -1 //decide whether to save form values
this.cookiestr=(this.togglebox.checked)? this.cookiestr+"toggleboxid:on;" : this.cookiestr
}
else //if checkbox isn't defined, just remove final "#" from cookie string
this.cookiestr=this.cookiestr.substr(0, this.cookiestr.length-1)+";"
setCookie(this.cookiename, this.cookiestr, this.persistdays)
}

RFormName.prototype.recallvalues=function(){ //populate form with saved values
var cookievalue=getCookie(this.cookiename)
if (cookievalue!=""){ //parse cookie, where cookie looks like: field1:value1#field2:value2...
var cookievaluepair=cookievalue.split("#")
for (var i=0; i<cookievaluepair.length; i++){
if (cookievaluepair[i].split(":")[0]!="toggleboxid" && this.getfield(cookievaluepair[i].split(":")[0]).type=="text")
this.getfield(cookievaluepair[i].split(":")[0]).value=unescape(cookievaluepair[i].split(":")[1])
else //else if name in name/value pair is "toggleboxid"
this.togglebox.checked=true
}
}
}

RFormName.prototype.addtoggle=function(attr){
this.togglebox=this.getfield(attr)
}

//Call this function if you wish to clear the user's cookie of any saved values for this form instantly
RFormName.prototype.clearcookie=function(){
setCookie(this.cookiename, "", -1)
}

RFormName.dotask=function(target, functionref, tasktype){
var tasktype=(window.addEventListener)? tasktype : "on"+tasktype
if (target.addEventListener)
target.addEventListener(tasktype, functionref, false)
else if (target.attachEvent)
target.attachEvent(tasktype, functionref)
}