var descriptionWin = null; function openDescriptionWin(title, description) { var ranInt = parseInt(100000 * Math.random()); //-------original //var url = 'http://www.tracer2.com/cgi/career/occupationdescription.asp?' + // 'title=' + escape(title) + '&description=' + escape(description); //----------original ends //alert(title + '\n' + description); var url = 'http://www.tracer2.com/cgi/career/occupationdescription.asp?' + 'title=' + escape(title) + '&description=' + escape(description); var name = 'descWin' + ranInt.toString(); var features = 'width=300,height=150,scrollbars=yes,toolbar=no'; if(descriptionWin && !descriptionWin.closed) { descriptionWin.location = url; } else { descriptionWin = window.open(url, name, features); } descriptionWin.focus(); } function closeWin() { if(descriptionWin && descriptionWin.open && !descriptionWin.closed) { descriptionWin.close(); descriptionWin = null; } } //------------------------------------------------------------------------------------for zipcode var openZipCodeWindow; function openZipCodeWin(url) { var ranInt = parseInt(100000 * Math.random()); var name = 'Zipcode' + ranInt.toString(); var features = 'width=300,height=250,scrollbars=no,resizable=no,menubar=no'; if(openZipCodeWindow && !openZipCodeWindow.closed) { openZipCodeWindow.location = url; } else { openZipCodeWindow = window.open(url, name, features); } openZipCodeWindow.focus(); } function closeZipCodeWindow() { if(openZipCodeWindow && openZipCodeWindow.open && !openZipCodeWindow.closed) { openZipCodeWindow.close(); openZipCodeWindow = null; } } //------------------------------------------------------------------------------------------------- //------------------------------------------------------------------------------------open ajb pop up var openJobWindow; function openJobWin(url) { var ranInt = parseInt(100000 * Math.random()); var name = 'Jobs' + ranInt.toString(); var features = 'width=500,height=450,scrollbars=no,resizable=yes,menubar=no'; if(openJobWindow && !openJobWindow.closed) { openJobWindow.location = url; } else { openJobWindow = window.open(url, name, features); } openJobWindow.focus(); } function closeJobWin() { if(openJobWindow && openJobWindow.open && !openJobWindow.closed) { openJobWindow.close(); openJobWindow = null; } } //------------------------------------------------------------------------------------------------- window.onunload = closeWin; window.onunload = closeZipCodeWindow; window.onunload = closeJobWin;