Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/88.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 重新加载div内容并对表元素进行排序_Javascript_Jquery_Ajax_Sorttable.js - Fatal编程技术网

Javascript 重新加载div内容并对表元素进行排序

Javascript 重新加载div内容并对表元素进行排序,javascript,jquery,ajax,sorttable.js,Javascript,Jquery,Ajax,Sorttable.js,我可以使用ajax重新加载div内容,但无法对表内容进行排序sorttable.js不起作用 我已经浪费了很多时间来寻找解决方案。请任何人建议我如何重新加载div内容并对表进行排序 xmlHttp.onreadystatechange = function(){ if(xmlHttp.readyState==4){ document.getElementById('displayarea').innerHTML = xmlHttp.responseText;

我可以使用ajax重新加载div内容,但无法对表内容进行排序<使用ajax重新加载div后,code>sorttable.js不起作用

我已经浪费了很多时间来寻找解决方案。请任何人建议我如何重新加载div内容并对表进行排序

xmlHttp.onreadystatechange = function(){ 
    if(xmlHttp.readyState==4){ 
        document.getElementById('displayarea').innerHTML = xmlHttp.responseText;
        setTimeout('AutoRefreshValid()',75*1000); // JavaScript function calls AutoRefresh() every 75 seconds 
    } 
} 

xmlHttp.open("GET","RPT_STATUS_AJAX_DIV_REAL_ADMIN.jsp?order=<%=strOrder%>&Order‌​By=<%=strOrderBy%>",true); 

xmlHttp.send(null);
xmlHttp.onreadystatechange=function(){
如果(xmlHttp.readyState==4){
document.getElementById('displayarea')。innerHTML=xmlHttp.responseText;
setTimeout('AutoRefreshValid()',75*1000);//JavaScript函数每75秒调用一次AutoRefresh()
} 
} 
open(“GET”、“RPT\u STATUS\u AJAX\u DIV\u REAL\u ADMIN.jsp”?order=&order‌​By=,true);
xmlHttp.send(空);

当ajax调用完成时,请调用可排序函数。下面给出了一个简单的原型

$.ajax({
  url: 'your_url',
  success:function(resp) {
    // put content in div

    $('element').sortable();
  }
});

请提供代码的详细信息..xmlHttp.onreadystatechange=function(){if(xmlHttp.readyState==4){document.getElementById('displayarea')。innerHTML=xmlHttp.responseText;setTimeout('AutoRefreshValid()',75*1000);//JavaScript函数调用AutoRefresh()每75秒}xmlHttp.open(“GET”、“RPT\u STATUS\u AJAX\u DIV\u REAL\u ADMIN.jsp?order=&OrderBy=”,true);xmlHttp.send(空);使用简单的js和ajax函数,你可以解释更多如何调用和在哪里调用。甚至我也需要修复表头。