I have two input fields "#HTML" and "#javascript" and a "#results" div
field.
Once the submit button is pressed I want the contents of #HTML to
appear in #results and any javascript functionality in #javascript to
be applied ONLY to the the contents of the #results div.

I know how to get the contents of #HTML into #results easy enough, but
I've had a hard time trying to get the #javascript to apply to
#results only.

I've tried the eval() function with many different combinations of
other things. I also noticed this Function(element, function) in this
post http://www.nabble.com/eval-vs.-Function-td15027113s27240.html but
not quite sure how to use it as I can't find a definition anywhere
although I seem to be able to call this Function function (is it a
javascript or jQuery function??)

This sounds like an easy enough thing to do so I'm sure I'm just going
about it the wrong way.

Thanks in advance.

Tim.

Reply via email to