// mains JavaScript Document // image preloader used top cache topnav on states // Preload( '01.gif', '02.gif' ); function Preload() { var args = Preload.arguments; document.imageArray = new Array(args.length); for(var i=0; i','',200, 50); } function Clickheretoprintold(page1) { updateprintlog(page1); //if (window.print) window.print(); var disp_setting="toolbar=yes,location=no,directories=no,menubar=yes,"; disp_setting+="scrollbars=yes,width=740, height=600, left=100, top=25"; //var content_vlue = document.getElementById("contentArea").innerHTML; //var content_vlue = document.getElementsByTagName("body").item(0).innerHTML; var content_vlue = document.getElementsByTagName("body").item(0).innerHTML; var bodyid = document.getElementsByTagName("body").item(0).getAttribute("id"); var docprint=window.open("","",disp_setting); docprint.document.open(); //docprint.document.write('Print'); //docprint.document.write('Print'); docprint.document.write('Print'); docprint.document.write(''); docprint.document.write(content_vlue); docprint.document.write(''); docprint.document.close(); docprint.focus(); } function Clickheretoprint(page1) { updateprintlog(page1); //if (window.print) window.print(); var disp_setting="toolbar=yes,location=no,directories=no,menubar=yes,"; disp_setting+="scrollbars=yes,width=740, height=600, left=100, top=25"; //var content_vlue = document.getElementById("contentArea").innerHTML; //var content_vlue = document.getElementsByTagName("body").item(0).innerHTML; var content_vlue = document.getElementsByTagName("body").item(0).innerHTML; var bodyid = document.getElementsByTagName("body").item(0).getAttribute("id"); var userinfo = document.getElementById("userinfo").innerHTML; var docprint=window.open("","",disp_setting); docprint.document.open(); //docprint.document.write('Print'); //docprint.document.write('Print'); //docprint.document.write('Print'); docprint.document.write('Print'); docprint.document.write(''); //docprint.document.write(userinfo + '
'); docprint.document.write(content_vlue); docprint.document.write(''); docprint.document.close(); docprint.focus(); } function Clickheretoprintdirect(page1) { updateprintlog(page1); //alert(page1); //popupsize('e0_Printlog.jsp?page=' + page1,'',200, 50); if (window.print) window.print(); } function popupsize(URL, Title, width, height) { var winwidth = width; var winheight = height; var screenW = 800, screenH = 600; var wintop = 50, winleft = 50; screenW = screen.width; screenH = screen.height; winleft = (screenW - winwidth) / 2; wintop = (screenH - winheight) / 2; eval("window.open(URL, Title, 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=1,width='+ winwidth + ',height=' + winheight + ',left = ' + winleft + ',top = ' + wintop + '');"); } function popupload(URL, Title, width, height, body) { var winwidth = width; var winheight = height; var screenW = 800, screenH = 600; var wintop = 50, winleft = 50; screenW = screen.width; screenH = screen.height; winleft = (screenW - winwidth) / 2; wintop = (screenH - winheight) / 2; var disp_setting='toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width='+ winwidth + ',height=' + winheight + ',left = ' + winleft + ',top = ' + wintop; var docprint=window.open("","",disp_setting); docprint.document.open(); docprint.document.write(''+Title+''); docprint.document.write(''); docprint.document.write(body); docprint.document.write(''); docprint.document.close(); docprint.focus(); } function popup(URL, Title) { var winwidth = 740; var winheight = 500; var screenW = 800, screenH = 600; var wintop = 50, winleft = 50; screenW = screen.width; screenH = screen.height; winleft = (screenW - winwidth) / 2; wintop = (screenH - winheight) / 2; eval("window.open(URL, Title, 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width='+ winwidth + ',height=' + winheight + ',left = ' + winleft + ',top = ' + wintop + '');"); } function fppopup(URL, Title) { var winwidth = 740; var winheight = 400; var screenW = 400, screenH = 300; var wintop = 50, winleft = 50; screenW = screen.width; screenH = screen.height; winleft = (screenW - winwidth) / 2; wintop = (screenH - winheight) / 2; eval("window.open(URL, Title, 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width='+ winwidth + ',height=' + winheight + ',left = ' + winleft + ',top = ' + wintop + '');"); } function quizpopup(URL, Title) { var winwidth = 740; var winheight = 350; var screenW = 400, screenH = 300; var wintop = 50, winleft = 50; screenW = screen.width; screenH = screen.height; winleft = (screenW - winwidth) / 2; wintop = (screenH - winheight) / 2; eval("window.open(URL, Title, 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width='+ winwidth + ',height=' + winheight + ',left = ' + winleft + ',top = ' + wintop + '');"); } function opennew(URL, Title) { var winwidth = 740; var winheight = 500; var screenW = 800, screenH = 600; var wintop = 50, winleft = 50; var handle; screenW = screen.width - 10; //availWidth - 5; screenH = screen.height - 10; //availHeight - 5 ; winleft = (screenW - winwidth) / 2; wintop = (screenH - winheight) / 2; //eval("handle = window.open(URL, Title, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width='+ screenW + ',height=' + screenH + ',left = 0,top = 0');"); eval("handle = window.open(URL, Title, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1');"); } function populateold() { var objframe = document.getElementById('frame1'); var objdiv = document.getElementById('framediv1'); //alert(document.frames['frame1'].innerHTML); //alert(objframe.contentDocument.body.innerHTML); //Worked only in Firefox //alert(document.getElementById('frame1').document.getElementById('contentarea').innerHTML); Working only in IE //alert(parent.frame1.document.getElementById('contentarea').innerHTML); if (document.frames) { //alert(document.frames[0].document.getElementById('contentarea').innerHTML); objdiv.innerHTML = '
' + document.frames[0].document.getElementById('contentarea').innerHTML + '
'; } else { //alert(objframe.contentDocument.body.innerHTML); objdiv.innerHTML = '
' + objframe.contentDocument.body.innerHTML + '
'; } var objframe2 = document.getElementById('frame2'); var objdiv2 = document.getElementById('framediv2'); //alert(document.frames['frame1'].innerHTML); //alert(objframe.contentDocument.body.innerHTML); //Worked only in Firefox //alert(document.getElementById('frame1').document.getElementById('contentarea').innerHTML); Working only in IE //alert(parent.frame1.document.getElementById('contentarea').innerHTML); if (document.frames) { //alert(document.frames[0].document.getElementById('contentarea').innerHTML); objdiv2.innerHTML = '
' + document.frames[1].document.getElementById('contentarea').innerHTML + '
'; } else { //alert(objframe.contentDocument.body.innerHTML); objdiv2.innerHTML = '
' + objframe2.contentDocument.body.innerHTML + '
'; } document.getElementById('loading').style.display='none'; document.getElementById('doneloading').style.display='block'; } function populate(num) { if (num <= 0) { return; } var objframe; var objdiv; var str; var secid; var iFrame; for(var i=1; i<=num; i++) { objframe = document.getElementById('frame'+i); objdiv = document.getElementById('framediv'+i); //secid = objdiv.innerHTML; if (document.frames) { str = document.frames[i-1].document.getElementById('contentarea').innerHTML; secid = document.frames[i-1].document.getElementsByTagName('body').item(0).getAttribute('id'); } else { str = objframe.contentDocument.body.innerHTML; secid = objframe.contentDocument.body.id; } objdiv.innerHTML = '
' + str + '
'; } // Done. document.getElementById('loading').style.display='none'; document.getElementById('doneloading').style.display='block'; window.print(); }