собственно сабж
поискал в гугле, ничего особо не прегледялось (
пока что остановился на таком решении
I have had the same problem but I found a workaround which is following. Note..it does not work in IE but works beautifully in Netscape and Firefox. May be you can tell me what is the problem with IE.
1 - from your ajax script put a id on your script like.
<script id="scriptFromAjax">
2 - On Success from ajax add the following line.
var response = o.responseText;
document.getElementById("ajaxresponseDiv").innerHTML = response;
//this is where you get all your script contents.
var scriptEle = document.getElementById('scriptFromAjax')
if(scriptEle!=null){
LoadJS(scriptEle.innerHTML);
}
3- Paste the following function in your receiving page. Put a div tag with id=dinamicJScontainer.
function LoadJS(theScript)
{
var newElem = document.createElement("script");
var elemJS = document.getElementById("dinamicJScontainer");
newElem.setAttribute("language","JavaScript1.2");
newElem.setAttribute("type","text/javascript");
//IE is failing on following line.
newElem.innerHTML = theScript;
alert(newElem.innerHTML );
elemJS.appendChild(newElem);
eliminar("dinamicJScontainer");
};
4- Optional -- call the following function if you want to clear the contents of jJavascript.
function eliminar(x){
while(document.getElementById(x).childNodes.length>0){
document.getElementById(x).removeChild(document.getElementById(x).childNodes
[0]);}
};
(http://forums.devx.com/showthread.php?t=163943)
возможно тут что-нибудь посоветуют =)
ps возможно есть какие-то встроенные ф-цию у jquery, prototyp'a ?
thx
Форум —
Development

