hi,
i need load a url in a div i have found many samples that work in that way,
the problem is that i need javascript working in the destination link
and for some reason the javascript dont work in the div that i load.
there is any way to resolve this issue?
what i need to do is load a url and that url have css and javascript that must
be working as loaded from a regular browser.
thanks a lot for your help
:)

The problem is that any additional JavaScript code returned will NOT be evaluated. I've run into this problem a few times myself; there are workarounds, such as an example found here on an old thread:

http://www.daniweb.com/forums/thread53137.html

.. But I honestly believe the best bet is to not rely on evaluating mixed HTML/SCRIPT at all, and instead find a way to write your JavaScript/AJAX functions so that they only update the HTML and then invoke additional JavaScript functions (perhaps as a callback) which do the additional code. Sometimes it can be really tricky to figure out effective ways to do this, but it is always possible if you put enough thought into it. I know it can be tricky because I've had to completely rethink how I did many things, but it can always be done!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.