I am getting an issue when loading the JSP page content via an AJAX call. What i am doing is loading the same page via AJAX call and the java script function values are dynamic values taking from the session.
The problem is that it’s not executing the latest java script that comes in the Ajax page content.
sending an ajax call to the same page and taking the content to ajaxpagecontent variable
<input type="hidden" id="amount" name="amount"/>
<input type="button" id="add" name="add" onclick="addmyselection();"/>
Normal body content
It is madness at this point to do Ajax "by hand". As Eric pointed out, jQuery, or any of the other Ajax-enabled libraries, take care of lots of little nuances (such as script evaluation) that are a pain in the rear to take care of yourself.