Does this work?

The documentation at http://msdn.microsoft.com/ieupdate/activexchanges.asp
states that:

"The control is blocked if the script that creates the control is in the
same file as the HTML for the Web page. For the control to load without user
input, the script must be in a separate file."

The example goes on to doc.write the OBJECT tag from Sample.js. 

Does anyone know if IE6sp2b blocks script that passes OBJECT tag strings to
a separate script file (see example below)?

This would at least allow for code reuse by centrally maintaining a single
JS ReplaceContent(str) method in a separate library file, rather than create
a Factory that emits HTML for every OBJECT occurrence.

Does the occurrence of parameterized OBJECTS *anywhere* within the DOMs
SCRIPT nodes block the script?

Sample.htm
-----------------------------------
<HTML>
    <HEAD>
        <SCRIPT SRC="sample.js"></SCRIPT>
    </HEAD>

    <BODY>
        <SCRIPT>
    ReplaceContent('<OBJECT>');
    ReplaceContent ('<PARAM NAME="URL"
VALUE="http://msdn.microsoft.com/workshop/');
    ReplaceContent ('samples/author/dhtml/media/drums.wav"/>');
    ReplaceContent ('</OBJECT>');
}
        </SCRIPT>
    </BODY>
</HTML>

Sample.js
---------------------------------------
function ReplaceContent(str){
    document.write(str);
}


Thanks in advance for your feedback.


-Mike
Cubic Compass Software

Received on Wednesday, 8 October 2003 21:28:58 UTC