Greetings,

I am trying to develop a WEB page that will display a Jmol image and then have two sections along the side. In one section, the user can enter full HTML text into a form field, including Jmol.js calls (such as 'jmolButton'). The other panel can then load the code from the form field into the .innerHTML of the second section (a DIV). The goal is to let people test out code snippets before moving them into their final HTML files.

The transfer from the form field to the DIV.innerHTML is working well and code such as <b>dog</b> correctly displays the word 'dog' in bold. All HTML code is properly interpreted. However, when I include <script>jmolButton(..,..)</script>, everything from the opening script tag to the closing script tag is simply ignored. Other HTML code past that point displays correctly.

I'm guessing that I may be trying to do something that browsers don't allow - a security issue perhaps? Does anyone have any workarounds?

   To see what I have so far and test it out, go to:
       <http://people.chem.umass.edu/cmartin/Jmol/WingedHelixII>

Then click on 'Cmd' at the top and look down to 'Test Bed' and 'Preview'

Thanks,

Craig Martin
[EMAIL PROTECTED]



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to