/* FILE ARCHIVED ON 6:08:06 Aug 25, 2009 AND RETRIEVED FROM THE AN OPENWAYBACK INSTANCE ON 6:27:26 Sep 5, 2024. JAVASCRIPT APPENDED BY OPENWAYBACK, COPYRIGHT INTERNET ARCHIVE. ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C. SECTION 108(a)(3)). */ function goHelpPage(oForm) { var projParam = ''; if ( oForm.project ) projParam = '&project=' + oForm.project.value; document.location= oForm.action + '?page=help' + projParam; } function checkSearchDates(oForm,hElements) { var useDefault = typeof hElements == 'undefined'; var yearBeginName = useDefault ? 'searchTxtYearBegin' : hElements['yearBegin']; var yearEndName = useDefault ? 'searchTxtYearEnd' : hElements['yearEnd']; var monthBeginName = useDefault ? 'searchTxtMonthBegin' : hElements['monthBegin']; var monthEndName = useDefault ? 'searchTxtMonthEnd' : hElements['monthEnd']; //alert(oForm[yearBeginName]+' ' + yearBeginName); return false; var i; var j; var yearBegin = oForm[yearBeginName].value; var monthBegin = ''; var yearEnd = oForm[yearEndName].value; var monthEnd = ''; var dateBegin = ''; var dateEnd = ''; if (oForm[monthBeginName]) monthBegin = oForm[monthBeginName][oForm[monthBeginName].selectedIndex].value; if (oForm[monthEndName]) monthEnd = oForm[monthEndName][oForm[monthEndName].selectedIndex].value; dateBegin=yearBegin + monthBegin; dateEnd=yearEnd + monthEnd; if (isNaN(yearBegin) || (yearBegin != '' && yearBegin.length != 4)) { alert("Start year is invalid. Please enter a four digit year."); oForm[yearBeginName].value=''; oForm[yearBeginName].focus(); return false; } else if (isNaN(yearEnd) || (yearEnd != '' && yearEnd.length != 4)) { alert("End year is invalid. Please enter a four digit year."); oForm[yearEndName].value=''; oForm[yearEndName].focus(); return false; } else if (dateEnd < dateBegin && yearEnd != '' && !( yearBegin <= yearEnd && ( monthBegin == '' || monthEnd == '' )) ) { alert("End date is before start date."); oForm[yearEndName].focus(); return false; } else if (yearBegin == '' && monthBegin != '') { alert("Start month was selected with no start year."); oForm[yearBeginName].focus(); return false; } else if (yearEnd == '' && monthEnd != '') { alert("End month was selected with no end year."); oForm[yearEndName].focus(); return false; } // Test the form without submitting: if the 'testForm' flag is in QUERY if (window.location.search.indexOf('testForm') >= 0) { alert('All is OK.'); return false; } return true; } var mustValidateExport = 0; function validateExport(oForm) { if (window.location.search.indexOf('testForm') >= 0) { if (! confirm( 'single pub:'+oForm.elements['ID__mult'].checked + '\n all pubs:' + oForm.elements['ID_all'].checked + '\n mult pubs:' + oForm.elements['ID__mult'].length + '\n must validate:' + mustValidateExport ) ) return false; } if ( mustValidateExport ) { mustValidateExport = 0; // turn off for next click var message = ""; if ( !oForm.elements['ID__mult'] ) message = 'No publications were located. Please re-run the publications search.'; else if ( !oForm.elements['ID__mult'].checked && !oForm.elements['ID_all'].checked ) { // If "Add All" is not checked and (if "Add"-individual pub is not checked or there are multiple such "Add" checkboxes) message = 'No publications selected.\n Please select articles to include in the report by clicking on the checkbox.'; for ( var i=0; i0) alert(oForm.action); oForm.submit(); oForm.action = action; oForm.extra.name = ''; oForm.extra.value = ''; }