/* ****************************************************************** */ /* COPYRIGHT NOTICE */ /* This script is the property of davewilliamsmedia.com */ /* It may be copied in whole or in part, free of charge, for use */ /* on any other web site, provided that - */ /* (a) This copyright notice is left intact at the beginning of */ /* every script file containing any or all of the script code */ /* copied from this file, AND, */ /* (b) Any web site using such a script file displays a banner link */ /* to the guyslink.com web site, in the manner described on the */ /* guyslink.com site, in the Information/Links section. */ /* ****************************************************************** */ var contentresizing=false; function onloadjs(focusfield,blur) { var sdiv=document.getElementById&&!document.all? document.getElementById("ExpandableHole"):document.all['ExpandableHole']; if (sdiv) sdiv.style.height="100px"; if (focusfield!="") setfocusonid(focusfield,blur) setTimeout("resizehole()",100); setTimeout("resizehole()",200); } function onunloadjs() { } function setfocusonid(focusfield,blur) { var target=document.getElementById(focusfield); if (target) { target.focus(); if (blur=='Y') target.blur(); } } var lastwindowheight=-1; function resizehole() { window.onresize=resizehole; var obody=document.body; var sdiv=document.getElementById&&!document.all? document.getElementById("ExpandableHole"):document.all['ExpandableHole'] var mtab=document.getElementById&&!document.all? document.getElementById("mainTable"):document.all['mainTable'] var ptab=document.getElementById&&!document.all? document.getElementById("pageTable"):document.all['pageTable'] if ( (sdiv) && (mtab) && (ptab) ) { if (window.innerHeight) windowheight=window.innerHeight; else if (document.documentElement && document.documentElement.clientHeight) windowheight=document.documentElement.clientHeight; else if (document.body) windowheight=document.body.clientHeight; if (windowheight==lastwindowheight) return; var $wasIframeOpen=IsIframeOpen(); CloseIframe(true); docheight=obody.offsetHeight; sparewindowheight=windowheight-docheight; if ( (sparewindowheight<0) && (sdiv.offsetHeight>150) ) { window.onresize=null; sdiv.style.height="100px"; setTimeout(resizehole,100) return; } mainheight=mtab.offsetHeight; pageheight=ptab.offsetHeight+ptab.offsetTop; sparepageheight=mainheight-pageheight; if (sparewindowheight<0) sparewindowheight=0; if (sparepageheight<0) sparepageheight=0; newwindowheight=sdiv.offsetHeight+sparewindowheight+sparepageheight; if (newwindowheight<100) newwindowheight=100; //alert('windowheight='+windowheight+' docheight='+docheight+' sparewindowheight='+sparewindowheight+' mainheight='+mainheight+' pageheight='+pageheight+' sparepageheight='+sparepageheight+' oldwindowheight='+sdiv.offsetHeight+' newwindowheight='+newwindowheight); sdiv.style.height=String(newwindowheight)+"px"; lastwindowheight=windowheight; if ($wasIframeOpen) setTimeout("OpenIframe()",300); if (contentresizing) resizecontent(); } } function getposOffset(what, offsettype) { var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop; var parentEl=what.offsetParent; while (parentEl!=null) { totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop; parentEl=parentEl.offsetParent; } //var pagediv=document.getElementById&&!document.all? document.getElementById(menuid):document.all[menuid]; //totaloffset-=(offsettype=="left")? pagediv.offsetLeft : pagediv.offsetTop; return totaloffset; } var activedropdownobj = new Array(10); var activedropdownseq = new Array('0','0','0','0','0','0','0','0','0','0'); var activetimer=null; function enabledropdown(menulevel,menusequence,oanchor) { if (activetimer) { clearTimeout(activetimer); activetimer=null; } if ( (activedropdownobj[menulevel]) && (activedropdownseq[menulevel]!=menusequence) ) hidemenulevel(menulevel); menuid='DropdownMenu-'+menusequence; var omenu=document.getElementById&&!document.all? document.getElementById(menuid):document.all[menuid]; if ( (omenu) && (oanchor) ) { if (omenu.style) { if (omenu.style.display!='inline') { anchorheight=parseInt(oanchor.offsetHeight); anchorwidth=parseInt(oanchor.offsetWidth); if (menulevel>0) { omenu.style.left=(getposOffset(oanchor,"left")+anchorwidth)+"px"; omenu.style.top=(getposOffset(oanchor,"top"))+"px"; } else { omenu.style.left=getposOffset(oanchor,"left")+"px"; omenu.style.top=(getposOffset(oanchor,"top")+anchorheight)+"px"; } omenu.style.display='inline'; } omenu.style.visibility='visible'; } activedropdownobj[menulevel]=omenu; activedropdownseq[menulevel]=menusequence; } activetimer=setTimeout("hidedropdown()",250); } function disabledropdown(menulevel,menusequence,oanchor) { if (activedropdownseq[menulevel]!=menusequence) return; activedropdownseq[menulevel]=0; if (activetimer) { clearTimeout(activetimer); activetimer=null; } activetimer=setTimeout("hidedropdown()",250); } function hidedropdown() { activetimer=null; for (menulevel=9;menulevel>=0;menulevel--) { if (activedropdownseq[menulevel]>0) break; hidemenulevel(menulevel); } } function hidemenulevel(menulevel) { omenu=activedropdownobj[menulevel]; if (omenu) omenu.style.visibility='hidden'; activedropdownobj[menulevel]=null; activedropdownseq[menulevel]=0; } function clickdropdown(menuid,menusequence,oanchor) { return false; } var popupfail=0; function popuperror(msg,url,lno) { popupfail=1; return true; } function popup(link,targetWindow,width,height,screenX,screenY) { if (!width) width=800; if (!height) height=400; if (!screenX) screenX=20; if (!screenY) screenY=50; popupfail=0; window.onerror=popuperror profWindow=window.open(link.href,targetWindow, 'height='+height+',width='+width+',screenX='+screenX+',screenY='+screenY+',menubar=no,personalbar=no,resizable=yes,scrollbars=yes,toolbar=no'); window.onerror=null; if ( (popupfail==1) || (profWindow==null) ) { link.target=targetWindow; return true; } return false; } var nbpseq=0; function navigatebypost(linkElement,postUrl,postTarget) { var oform=document.getElementById&&!document.all? document.getElementById('xhtml_navigation'):document.all['xhtml_navigation']; if (oform) oinput=oform.elements['qs']; if ( (!linkElement.href) || (!oform) || (!oinput) ) return true; if (postUrl) targetUrl=postUrl; else targetUrl=linkElement.href; offset=targetUrl.indexOf('?'); if (offset>=0) { queryParm=targetUrl.substr(offset); targetUrl=targetUrl.substr(0,offset); } else queryParm='?'; nbpseq++; oform.action=targetUrl+'?qq='+nbpseq; if (postTarget) oform.target=postTarget; else if (linkElement.target) oform.target=linkElement.target; else oform.target=''; oinput.value=queryParm; oform.submit(); return false; } function ScrollToIndexRow(rowid) { var obj=document.getElementById&&!document.all? document.getElementById(rowid):document.all[rowid]; ScrollToIndexObject(obj); } function ScrollToIndexObject(obj) { if (obj.scrollIntoView) { obj.scrollIntoView(); return; } var offset=0; while (obj) { if (obj.className=='holeDiv') break; offset+=obj.offsetTop; obj=obj.parentNode; } if (obj) obj.scrollTop=offset; } function ShowIframe(selectedElement,iframeUrl) { var trElement=selectedElement; while (trElement) { if (trElement.nodeName=="TR") break; trElement=trElement.parentNode; } var xhole=document.getElementById&&!document.all? document.getElementById('ExpandableHole'):document.all['ExpandableHole']; var iframe=document.getElementById&&!document.all? document.getElementById('PopupIframe'):document.all['PopupIframe']; if ( (!xhole) || (!iframe) ) return true; iframe.src='about:blank'; if (iframeUrl) srcUrl=iframeUrl; else srcUrl=selectedElement.href; if (srcUrl.indexOf('?')>=0) iframe.src=srcUrl+'&iframe='+(xhole.offsetWidth); else iframe.src=srcUrl+'?iframe='+(xhole.offsetWidth); OpenIframe(); ScrollToIndexObject(trElement); return false; } function OpenIframe() { var xhole=document.getElementById&&!document.all? document.getElementById('ExpandableHole'):document.all['ExpandableHole']; var iframe=document.getElementById&&!document.all? document.getElementById('PopupIframe'):document.all['PopupIframe']; if ( (!xhole) || (!iframe) ) return; var totalHeight=xhole.offsetHeight+iframe.offsetHeight; if (xhole.offsetHeight>150) { var newiframeheight=totalHeight-150; if (newiframeheight>iframe.offsetHeight) { xhole.style.height="150px"; iframe.style.height=newiframeheight+"px"; } else { iframe.style.height=newiframeheight+"px"; xhole.style.height="150px"; } } iframe.style.width=xhole.offsetWidth+"px"; } function CloseIframe(retainContent) { var xhole=document.getElementById&&!document.all? document.getElementById('ExpandableHole'):document.all['ExpandableHole']; var iframe=document.getElementById&&!document.all? document.getElementById('PopupIframe'):document.all['PopupIframe']; if ( (!xhole) || (!iframe) ) return true; totalHeight=xhole.offsetHeight+iframe.offsetHeight; iframe.style.height="0px"; iframe.style.width="1px"; if (!retainContent) iframe.src='about:blank'; xhole.style.height=totalHeight+"px"; return true; } function IsIframeOpen() { var iframe=document.getElementById&&!document.all? document.getElementById('PopupIframe'):document.all['PopupIframe']; if (!iframe) return false; if (iframe.offsetHeight>0) return true; return false; } /* A JavaScript implementation of the SHA family of hashes, as defined in FIPS * PUB 180-2 as well as the corresponding HMAC implementation as defined in * FIPS PUB 198a * * Version 1.3 Copyright Brian Turek 2008-2010 * Distributed under the BSD License * See http://jssha.sourceforge.net/ for more information * * Several functions taken from Paul Johnson */ (function(){var charSize=8,b64pad="",hexCase=0,str2binb=function(a){var b=[],mask=(1<>5]|=(a.charCodeAt(i/charSize)&mask)<<(32-charSize-(i%32))}return b},hex2binb=function(a){var b=[],length=a.length,i,num;for(i=0;i>3]|=num<<(24-(4*(i%8)))}else{return"INVALID HEX STRING"}}return b},binb2hex=function(a){var b=(hexCase)?"0123456789ABCDEF":"0123456789abcdef",str="",length=a.length*4,i,srcByte;for(i=0;i>2]>>((3-(i%4))*8);str+=b.charAt((srcByte>>4)&0xF)+b.charAt(srcByte&0xF)}return str},binb2b64=function(a){var b="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"+"0123456789+/",str="",length=a.length*4,i,j,triplet;for(i=0;i>2]>>8*(3-i%4))&0xFF)<<16)|(((a[i+1>>2]>>8*(3-(i+1)%4))&0xFF)<<8)|((a[i+2>>2]>>8*(3-(i+2)%4))&0xFF);for(j=0;j<4;j+=1){if(i*8+j*6<=a.length*32){str+=b.charAt((triplet>>6*(3-j))&0x3F)}else{str+=b64pad}}}return str},rotr=function(x,n){return(x>>>n)|(x<<(32-n))},shr=function(x,n){return x>>>n},ch=function(x,y,z){return(x&y)^(~x&z)},maj=function(x,y,z){return(x&y)^(x&z)^(y&z)},sigma0=function(x){return rotr(x,2)^rotr(x,13)^rotr(x,22)},sigma1=function(x){return rotr(x,6)^rotr(x,11)^rotr(x,25)},gamma0=function(x){return rotr(x,7)^rotr(x,18)^shr(x,3)},gamma1=function(x){return rotr(x,17)^rotr(x,19)^shr(x,10)},safeAdd_2=function(x,y){var a=(x&0xFFFF)+(y&0xFFFF),msw=(x>>>16)+(y>>>16)+(a>>>16);return((msw&0xFFFF)<<16)|(a&0xFFFF)},safeAdd_4=function(a,b,c,d){var e=(a&0xFFFF)+(b&0xFFFF)+(c&0xFFFF)+(d&0xFFFF),msw=(a>>>16)+(b>>>16)+(c>>>16)+(d>>>16)+(e>>>16);return((msw&0xFFFF)<<16)|(e&0xFFFF)},safeAdd_5=function(a,b,c,d,e){var f=(a&0xFFFF)+(b&0xFFFF)+(c&0xFFFF)+(d&0xFFFF)+(e&0xFFFF),msw=(a>>>16)+(b>>>16)+(c>>>16)+(d>>>16)+(e>>>16)+(f>>>16);return((msw&0xFFFF)<<16)|(f&0xFFFF)},coreSHA2=function(j,k,l){var a,b,c,d,e,f,g,h,T1,T2,H,lengthPosition,i,t,K,W=[],appendedMessageLength;if(l==="SHA-224"||l==="SHA-256"){lengthPosition=(((k+65)>>9)<<4)+15;K=[0x428A2F98,0x71374491,0xB5C0FBCF,0xE9B5DBA5,0x3956C25B,0x59F111F1,0x923F82A4,0xAB1C5ED5,0xD807AA98,0x12835B01,0x243185BE,0x550C7DC3,0x72BE5D74,0x80DEB1FE,0x9BDC06A7,0xC19BF174,0xE49B69C1,0xEFBE4786,0x0FC19DC6,0x240CA1CC,0x2DE92C6F,0x4A7484AA,0x5CB0A9DC,0x76F988DA,0x983E5152,0xA831C66D,0xB00327C8,0xBF597FC7,0xC6E00BF3,0xD5A79147,0x06CA6351,0x14292967,0x27B70A85,0x2E1B2138,0x4D2C6DFC,0x53380D13,0x650A7354,0x766A0ABB,0x81C2C92E,0x92722C85,0xA2BFE8A1,0xA81A664B,0xC24B8B70,0xC76C51A3,0xD192E819,0xD6990624,0xF40E3585,0x106AA070,0x19A4C116,0x1E376C08,0x2748774C,0x34B0BCB5,0x391C0CB3,0x4ED8AA4A,0x5B9CCA4F,0x682E6FF3,0x748F82EE,0x78A5636F,0x84C87814,0x8CC70208,0x90BEFFFA,0xA4506CEB,0xBEF9A3F7,0xC67178F2];if(l==="SHA-224"){H=[0xc1059ed8,0x367cd507,0x3070dd17,0xf70e5939,0xffc00b31,0x68581511,0x64f98fa7,0xbefa4fa4]}else{H=[0x6A09E667,0xBB67AE85,0x3C6EF372,0xA54FF53A,0x510E527F,0x9B05688C,0x1F83D9AB,0x5BE0CD19]}}j[k>>5]|=0x80<<(24-k%32);j[lengthPosition]=k;appendedMessageLength=j.length;for(i=0;i(keyBinLen/8)){keyToUse[15]&=0xFFFFFF00}for(i=0;i<=15;i+=1){keyWithIPad[i]=keyToUse[i]^0x36363636;keyWithOPad[i]=keyToUse[i]^0x5C5C5C5C}retVal=coreSHA2(keyWithIPad.concat(this.strToHash),512+this.strBinLen,c);retVal=coreSHA2(keyWithOPad.concat(retVal),512+hashBitSize,c);return(e(retVal))}};window.jsSHA=jsSHA}()); function SecureSubmit(formObject) { var chalstring=""; var shaObj; for (i=0; i0) ) { var soff=formObject.elements[i].name.lastIndexOf("["); var eoff=formObject.elements[i].name.lastIndexOf("]"); chalstring=formObject.elements[i].name.substring(soff+1,eoff); shaObj = new jsSHA(chalstring, "ASCII"); formObject.elements[i].value=shaObj.getHash("SHA-256", "HEX"); } if (formObject.elements[i].type=="password") { var eoff=formObject.elements[i].name.lastIndexOf("]"); var hashElementName=formObject.elements[i].name.substring(0,eoff)+"hash]"; var hashElementObj=formObject.elements[hashElementName]; var initElementName=formObject.elements[i].name.substring(0,eoff)+"init]"; var initElementObj=formObject.elements[initElementName]; var hashCalc=true; if (initElementObj) { //Inhibit hash recalculation if field value unchanged from initial value when form was output if (initElementObj.value==formObject.elements[i].value) hashCalc=false; } if ( (hashElementObj) && (hashCalc) ) { var pstrimmed=formObject.elements[i].value.replace(/^\s\s*/, '').replace(/\s\s*$/, '').toLowerCase(); var pslen=pstrimmed.length; shaObj = new jsSHA(pstrimmed.toLowerCase(),"ASCII"); hashElementObj.value=shaObj.getHash("SHA-256", "HEX")+String(pslen); if (formObject.elements[i].name.indexOf('[cpassword]')>=0) { shaObj = new jsSHA(chalstring+hashElementObj.value,"ASCII"); hashElementObj.value=shaObj.getHash("SHA-256", "HEX"); } } if (hashElementObj) formObject.elements[i].value=formObject.elements[i].value.replace(/./g,'_'); } } formObject.submit(); return false; }