mirror of
https://github.com/vrana/adminer.git
synced 2025-08-21 05:41:27 +02:00
Run <script> in AJAX
This commit is contained in:
@@ -236,6 +236,14 @@ function ajaxSend(url, data) {
|
||||
if (currentState == ajaxState) {
|
||||
clearTimeout(ajaxTimeout);
|
||||
setHtml('content', text);
|
||||
var content = document.getElementById('content');
|
||||
var scripts = content.getElementsByTagName('script');
|
||||
var length = scripts.length; // required to avoid infinite loop
|
||||
for (var i=0; i < length; i++) {
|
||||
var script = document.createElement('script');
|
||||
script.text = scripts[i].text;
|
||||
content.appendChild(script);
|
||||
}
|
||||
if (window.jush) {
|
||||
jush.highlight_tag('code', 0);
|
||||
}
|
||||
|
Reference in New Issue
Block a user