// icr function checkformSubscribe() { if (document.subscribeform.elements['email'].value == "") { alert("Please enter your email address."); document.subscribeform.elements['email'].focus(); return false; } if (document.subscribeform.elements[6].checked) { return true; } else if (document.subscribeform.elements[7].checked) { return true; } else if (document.subscribeform.elements[8].checked) { return true; } else { alert("Please select at least one publication to subscribe to."); document.subscribeform.elements['email'].focus(); return false; } return true; } function checkformSubscribe_Confirmation() { if (document.subscribeform.elements['f_captcha'].value == "") { alert("Please enter the text in the image."); document.subscribeform.elements['f_captcha'].focus(); return false; } var entered = document.subscribeform.elements['f_captcha'].value.toLowerCase(); var expected = document.subscribeform.elements['f_answer_captcha'].value.toLowerCase(); if (entered != expected) { alert("Text entered does not match image. Please reenter."); document.subscribeform.elements['f_captcha'].focus(); return false; } return true; } var emailCleared = false; function clearEmailSubscribe() { if(emailCleared == false) { document.subscribeform.elements['email'].value = ""; emailCleared = true; } } function icrWindow(theURL,winName,features) { window.open(theURL,winName,features); } function bannerPreview(ID) { pwin = window.open('/banner/preview/'+ID+'/', 'preview', 'width=240,height=140'); } function popupWindow(url) { window.open(url, 'popupWindow', 'status=no,menubar=no,scrollbars=yes,resizable=yes,width=500,height=400,screenX=150,screenY=150,top=150,left=150'); } function linkAddress(strAddress) { url = "http://maps.google.com/maps?q=" + encodeURI(strAddress); window.open(url, 'popupWindow'); } function bibleLexicon(num, book, chapter, verse) { lexWin = window.open("/bible?module=bible&action=lexicon&page="+num+"&book="+book+"&chapter="+chapter+"&verse="+verse,"lexicon","width=640,height=480,scrollbars=yes,resizable=yes"); } function aboutDefenders() { defWin = window.open("/bible?module=bible&action=aboutdefenders","defenders","width=480,height=360,scrollbars=yes"); } function browseServer(module, action, type) { // Set the browser window feature. var iWidth = 700; var iHeight = 700; var iLeft = (screen.width - iWidth) / 2 ; var iTop = (screen.height - iHeight) / 2 ; var sOptions = "toolbar=no,status=no,resizable=yes,dependent=yes" ; sOptions += ",width=" + iWidth ; sOptions += ",height=" + iHeight ; sOptions += ",left=" + iLeft ; sOptions += ",top=" + iTop ; // Open the browser window. var oWindow = window.open('/home?module='+module+'&action='+action+'&type='+type, "BrowseWindow", sOptions ) ; } function fileManagerWindow() { // Open the browser window. var fileManagerWindow = window.open('/icrFinder/icrFinder.html', 'FileManagerWindow', 'toolbar=no,status=no,resizable=yes,width=700,height=720') ; } function setUrl(type, url) { document.getElementById('f_'+type).value = url ; } function setUpload(type, url) { window.opener.setUrl(type, url); window.close(); } function parentOpen(url) { if(window.opener) { window.opener.location = url; } else { window.location.href = url; } } function addBookmark() { if (window.sidebar) { // firefox window.sidebar.addPanel(window.document.title, window.document.location, ""); } else if(window.opera && window.print) { // opera var elem = document.createElement('a'); elem.setAttribute('href',window.document.location); elem.setAttribute('title',window.document.title); elem.setAttribute('rel','sidebar'); elem.click(); } else if(document.all) {// ie window.external.AddFavorite(window.document.location, window.document.title); } } function microtime (get_as_float) { // Returns either a string or a float containing the current time in seconds and microseconds // // version: 909.322 // discuss at: http://phpjs.org/functions/microtime // + original by: Paulo Ricardo F. Santos // * example 1: timeStamp = microtime(true); // * results 1: timeStamp > 1000000000 && timeStamp < 2000000000 var now = new Date().getTime() / 1000; var s = parseInt(now, 10); return (get_as_float) ? now : (Math.round((now - s) * 1000) / 1000) + ' ' + s; } function toggleDivDisplay(id) { // displays or hides a