function openWindow(strLocation,nbrWidth,nbrHeight) { var strOptions = "location=yes,menubar=yes,toolbar=yes,scrollbars=yes,width=" + nbrWidth + ",height=" + nbrHeight; var nbrRandom=Math.floor(Math.random()*999); var objWindow = window.open(strLocation, String(nbrRandom), strOptions); objWindow.focus(); return true; } function setPopUpLinks() { var hrefs = document.getElementsByTagName('A'); for (i in hrefs) { if (hrefs[i].className == 'pop_up') { hrefs[i].onclick = function() { window.open(this.href); return false; } hrefs[i].onkeypress = function() { window.open(this.href); return false; } } } } function changeIt(){ document.getElementById("amtdiv").innerHTML="
Amount:*$  
" return true; } function changeItBack(){ document.getElementById("amtdiv").innerHTML=" " return false; } function addFields(){ document.getElementById("abovediv").innerHTML="

*Virginia law requires that we report the occupation and employer of those who give over $100

Employer:*  
Occupation:*  
" return true; } function removeFields(){ document.getElementById("abovediv").innerHTML=" " return false; } function registrationDonCheck() { if(document.getElementById("amountdiv")) { if(document.form_don.amount.value == "") { alert('Please enter an amount'); document.form_don.amount.focus(); return false; } } if(document.getElementById("amountdiv") && document.form_don.amount.value < 100) { } else if(document.getElementById("newfieldsdiv")) { if(document.form_don.company.value == "") { alert('Please enter your employer'); document.form_don.company.focus(); return false; } if(document.form_don.position.value == "") { alert('Please enter your position'); document.form_don.position.focus(); return false; } } if(document.form_don.first_name.value == "") { alert('Please enter your first name.'); document.form_don.first_name.focus(); return false; } if(document.form_don.last_name.value == "") { alert('Please enter your last name.'); document.form_don.last_name.focus(); return false; } if(document.form_don.address1.value == "") { alert('Please enter address one.'); document.form_don.address1.focus(); return false; } if(document.form_don.city.value == "") { alert('Please enter city.'); document.form_don.city.focus(); return false; } if(document.form_don.state.value == "") { alert('Please select state.'); document.form_don.state.focus(); return false; } if(document.form_don.country.value == "") { alert('Please select country.'); document.form_don.country.focus(); return false; } if(document.form_don.zip.value == "") { alert('Please enter zip code.'); document.form_don.zip.focus(); return false; } if(document.form_don.phone.value == "") { alert('Please enter your telephone number.'); document.form_don.phone.focus(); return false; } if(document.form_don.email.value.search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) == -1) { alert('Please enter a valid email value.'); document.form_don.email.focus(); return false; } if(document.form_don.email_confirm.value != document.form_don.email.value) { alert("The email your typed in doesn't match."); document.form_don.email_confirm.focus(); return false; } if(!document.form_don.read_policy.checked) { alert('You must agree to the Right Change policies.'); document.form_don.read_policy.focus(); return false; } if(document.form_don.cc_num.value == "") { alert('Please enter your credit card #.'); document.form_don.cc_num.focus(); return false; } if(document.form_don.cc_ccv.value== "") { alert('Please enter the secure code.'); document.form_don.cc_ccv.focus(); return false; } if(document.form_don.cc_name.value== "") { alert('Please enter your name on card.'); document.form_don.cc_name.focus(); return false; } if(document.form_don.cc_type.value== "") { alert('Please select your credit card type.'); document.form_don.cc_type.focus(); return false; } return true; } function SubmitDonForm(cform) { if(registrationDonCheck()){cform.submit();} } var help_parent = window.location; function help_popup() {window.open('/index.php/site/help','page','toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=600,height=550,left=50,top=50,titlebar=yes')} function registrationVolCheck() { if(document.form_vol.first_name.value == "") { alert('Please enter your first name.'); document.form_vol.first_name.focus(); return false; } if(document.form_vol.last_name.value == "") { alert('Please enter your last name.'); document.form_vol.last_name.focus(); return false; } if(document.form_vol.address1.value == "") { alert('Please enter address one.'); document.form_vol.address1.focus(); return false; } if(document.form_vol.city.value == "") { alert('Please enter city.'); document.form_vol.city.focus(); return false; } if(document.form_vol.state.value == "") { alert('Please select state.'); document.form_vol.state.focus(); return false; } if(document.form_vol.zip.value == "") { alert('Please enter zip code.'); document.form_vol.zip.focus(); return false; } if(document.form_vol.phone.value == "") { alert('Please enter your telephone number.'); document.form_vol.phone.focus(); return false; } if(document.form_vol.email.value.search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) == -1) { alert('Please enter a valid email value.'); document.form_vol.email.focus(); return false; } if(document.form_vol.email_confirm.value != document.form_vol.email.value) { alert("The email your typed in doesn't match."); document.form_vol.email_confirm.focus(); return false; } return true; } function SubmitVolForm(cform) { if(registrationVolCheck()){cform.submit();} } //Flash Detect Variables var flashinstalled = 0; var flashversion = 0; function checkFlash(nbrFlashversion) { if (nbrFlashversion < 1) { /* This Flash detection code was originally written by Peter-Paul Koch at http://www.quirksmode.org/. He has allowed for this to be freely distributed per his copyright located at http://www.quirksmode.org/about/copyright.html. */ if (navigator.plugins && navigator.plugins.length) { x = navigator.plugins["Shockwave Flash"]; if (x) { flashinstalled = 2; if (x.description) { y = x.description; nbrFlashversion = y.charAt(y.indexOf('.')-1); } } else { flashinstalled = 1; } if (navigator.plugins["Shockwave Flash 2.0"]) { flashinstalled = 2; nbrFlashversion = 2; } } else if (navigator.mimeTypes && navigator.mimeTypes.length) { x = navigator.mimeTypes['application/x-shockwave-flash']; if (x && x.enabledPlugin) { flashinstalled = 2; } else { flashinstalled = 1; } } } if(nbrFlashversion < 8) { switch(document.body.id) { case "homepage": removeFlashElement("homepage_video","content_center"); document.getElementById("content_center").className="homepage_image"; break; } if(getCookie("oldflash") != 1){ box = confirm("To view the video content on this site, please click \"OK\" to download the latest Flash plugin. To view the site without video, click \"Cancel\"."); if(box == true){window.location="http://www.macromedia.com/go/getflashplayer";} setCookie("oldflash","1",7,setCookieDomain(),"/"); setCookie("dialup","1",7,setCookieDomain(),"/"); } } } function noVideo(nbrVideo) { if(getCookie("dialup") != 1 || getCookie("oldflash") != 1) { var arrVideo = new Array(); //SWF Names arrVideo[0] = "bobm_hm"; if (getCookie(arrVideo[nbrVideo]) == 1) { if (document.getElementById(arrVideo[nbrVideo])) {getFlashMovieObject(arrVideo[nbrVideo]).SetVariable("makeItStop","1");} } else {setCookie(arrVideo[nbrVideo],"1",0,setCookieDomain(),"/");} } } function getFlashMovieObject(menu) { if (window.document[menu]) { return window.document[menu]; } if (navigator.appName.indexOf("Microsoft Internet")==-1) { if (document.embeds && document.embeds[menu]){ return document.embeds[menu]; } } else // if (navigator.appName.indexOf("Microsoft Internet")!=-1) { return document.getElementById(menu); } } function removeFlashElement(childDiv,parentDiv) { if(document.getElementById(childDiv)){ var objParent = document.getElementById(parentDiv); var objChild = document.getElementById(childDiv); objParent.removeChild(objChild); } } function CurrentTime() { time = new Date(); return time.getTime(); } function returnKBPS(kbps){ return kbps; } function GetKBPS(ST,section) { ET = CurrentTime(); Factor = 1000; DT = ((ET - ST)/Factor); DataSize = 29; kbps1 = (DataSize/DT); kbpsA = ((kbps1*8)*10*1.02); kbyteA = ((DataSize*10)/DT); kbps = (Math.round(kbpsA)/10); kbyte = (Math.round(kbyteA)/10); if (getCookie("dialup") == 1 || kbps <= 80) { switch(section) { case 1: removeFlashElement("homepage_video","content_center"); document.getElementById("content_center").className="homepage_image"; break; } setCookie("dialup","1",7,setCookieDomain(),"/"); } } function getCookie(strName) { var nbrStart = document.cookie.indexOf(strName + "="); var nbrLength = nbrStart + strName.length + 1; if ((!nbrStart) && (strName != document.cookie.substring(0, strName.length))) { return null; } if (nbrStart == -1) return null; var nbrEnd = document.cookie.indexOf(';', nbrLength); if (nbrEnd == -1) nbrEnd = document.cookie.length; return unescape(document.cookie.substring(nbrLength, nbrEnd)); } function setCookie(strName,strValue,strDuration,strDomain,strPath) { var strCookie=""; if (strDuration == 0) {strCookie=strName+"="+escape(strValue)+";DOMAIN="+strDomain+";PATH="+strPath;} else {strCookie=strName+"="+escape(strValue)+";EXPIRES="+getExpiryDate(strDuration)+";DOMAIN="+strDomain+";PATH="+strPath;} document.cookie=strCookie; if(!getCookie(strName)){ return false; } else{ return true; } } function deleteCookie(strName) {setCookie(strName,"",-1,setCookieDomain(),"/");} function getExpiryDate(intDays) { var strUTC; //This will hold the UTC value strToday = new Date(); //Get the current date. strToday.setTime(strToday.getTime() + 3600000*24*intDays); //Add the number of days to keep alive strUTC = strToday.toUTCString(); //Convert the UTC back to a string. return strUTC; //Return the date. } function setCookieDomain() { var strDomain = document.domain; strDomain.replace('www.',''); return '.'+strDomain; } //v1.0 //Copyright 2006 Adobe Systems, Inc. All rights reserved. function AC_AddExtension(src, ext) { if (src.indexOf('?') != -1) return src.replace(/\?/, ext+'?'); else return src + ext; } function AC_Generateobj(objAttrs, params, embedAttrs) { var str = ' '; str += '