//Function to open preview window function OpenPreviewWindow(formName){ now = new Date; submitAction = formName.action; submitTarget = formName.target; //Open the window first //winOpener('','preview',1,1,680,400) window.open('', 'preview','fullscreen=yes,scrollbars=yes') //Now submit form to the new window formName.action = 'RTE_popup_preview.asp?ID=' + now.getTime(); formName.target = 'preview'; formName.submit(); //Reset submission formName.action = submitAction; formName.target = submitTarget; } //Function to open pop up window function winOpener(theURL, winName, scrollbars, resizable, width, height) { winFeatures = 'left=' + (screen.availWidth-10-width)/2 + ',top=' + (screen.availHeight-30-height)/2 + ',scrollbars=' + scrollbars + ',resizable=' + resizable + ',width=' + width + ',height=' + height + ',toolbar=0,location=0,status=1,menubar=0' window.open(theURL, winName, winFeatures); } //Function to hover button icon function overIcon(iconItem){ iconItem.className='WebWizRTEbuttonOver'; } //Function to moving off button icon function outIcon(iconItem){ iconItem.className='WebWizRTEbutton'; } function casillaVerificacionBuena() { htmltext = '' editor = window.document.getElementById('WebWizRTE'); editor.contentWindow.focus(); editor.contentWindow.document.selection.createRange().pasteHTML(htmltext); } function casillaVerificacionMala() { htmltext = '' editor = window.document.getElementById('WebWizRTE'); editor.contentWindow.focus(); editor.contentWindow.document.selection.createRange().pasteHTML(htmltext); } function insertarCapa() { editor = window.document.getElementById('WebWizRTE'); //alert(editor.contentWindow.document.body.scrollTop); htmltext = '
This is a floating layer. Replace this text with your own text, images or other elements.
' editor.contentWindow.document.selection.createRange().pasteHTML(htmltext); var htmlinside = editor.contentWindow.document.body.innerHTML; editor.contentWindow.document.body.innerHTML = htmlinside; }