I am having a strange problem after creating an onclick popup. A popup window opens, but immediately hangs on IE8 (works fine in all other browsers, including IE6). But when adding the alert field as a show in JavaScript code, the popup works fine.
I am using **https** and not **http** , and I feel that the popup cannot load the JS file due to SSL .
This is how I generate the onclick event:
<a id="forgotPasswordLink" href="#" onclick="openSupportPage();"> Some Text </a>
The onclick function is defined as follows:
function openSupportPage() { var features = "width=700,height=400,status=yes,toolbar=no,menubar=no,location=no,scrollbars=yes"; var winId = window.open('', '', features); winId.focus(); winId.document.open(); winId.document.write('<html><head><title>' + document.title + '</title><link rel="stylesheet" href="./css/default.css" type="text/css">\n'); var is_ie6 = ( window.external && typeof window.XMLHttpRequest == "undefined"); alert(is_ie6); winId.document.write('<script src="../js/tiny_mce/tiny_mce.js" type="text/javascript">Script_IE8</script>\n'); winId.document.write('<script type="text/javascript">\n'); winId.document.write('function inittextarea() {\n'); winId.document.write('tinyMCE.init({ \n'); winId.document.write('elements : "content",\n'); winId.document.write('theme : "advanced",\n'); winId.document.write('readonly : true,\n'); winId.document.write('mode : "exact",\n'); winId.document.write('theme : "advanced",\n'); winId.document.write('readonly : true,\n'); winId.document.write('setup : function(ed) {\n'); winId.document.write('ed.onInit.add(function() {\n'); winId.document.write('tinyMCE.activeEditor.execCommand("mceToggleVisualAid");\n'); winId.document.write('});\n'); winId.document.write('}\n'); winId.document.write('});}</script>\n'); winId.document.write('</head><body onload="inittextarea()">\n'); winId.document.write(' \n'); var hiddenFrameHTML = document.getElementById("HiddenFrame").innerHTML; hiddenFrameHTML = hiddenFrameHTML.replace(/&/gi, "&"); hiddenFrameHTML = hiddenFrameHTML.replace(/</gi, "<"); hiddenFrameHTML = hiddenFrameHTML.replace(/>/gi, ">"); winId.document.write(hiddenFrameHTML); winId.document.write('<textarea id="content" rows="10" style="width:100%">\n'); winId.document.write(document.getElementById(top.document.forms[0].id + ":supportStuff").innerHTML); winId.document.write('</textArea>\n'); var hiddenFrameHTML2 = document.getElementById("HiddenFrame2").innerHTML; hiddenFrameHTML2 = hiddenFrameHTML2.replace(/&/gi, "&"); hiddenFrameHTML2 = hiddenFrameHTML2.replace(/</gi, "<"); hiddenFrameHTML2 = hiddenFrameHTML2.replace(/>/gi, ">"); winId.document.write(hiddenFrameHTML2); winId.document.write('</body></html>\n'); winId.document.close(); }
Please help me with this. I could provide more information about this if necessary.
I mentioned these posts already:
Additional information :