Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/google-chrome/4.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
引导表-->;通过Ajax ajaxRequest获取数据_Ajax - Fatal编程技术网

引导表-->;通过Ajax ajaxRequest获取数据

引导表-->;通过Ajax ajaxRequest获取数据,ajax,Ajax,我想使用引导表库 我希望通过ajax向表提供数据 我有以下代码: <table id="table" class="table text-center" data-toggle="table" data-ajax="ajaxRequest"

我想使用引导表库

我希望通过ajax向表提供数据

我有以下代码:

                          <table id="table" class="table text-center"
                            data-toggle="table"
                            data-ajax="ajaxRequest"
                            data-search="true"
                            data-show-refresh= "true"
                            data-show-export="true"
                            data-side-pagination="server"
                            data-pagination="true">

                            <thead>
                              <tr>
                                <th data-field="ID_Persona" >Responsable</th>
                                <th data-field="Nombre" >Sección</th>
                                <th data-field="ID_Responsable" >Prog.</th>
                                <th data-field="Responsable" >Realizado</th>
                                <th data-field="Prog" >%</th>
                              </tr>
                            </thead>
                          </table>


                            

责任的
塞西翁
掠夺。
实现
%
剧本

<script>
function ajaxRequest(params) {
  $.ajax({
      url: "nombre_api",
      type: "POST",
      dataType: "json",
        success: function(result){
          console.log('ajax.success: ', result);
                  params.success({ 

                });
        },
      error: function(er){
        console.log(er)
      }
    });}</script>

函数ajaxRequest(参数){
$.ajax({
url:“nombre_api”,
类型:“POST”,
数据类型:“json”,
成功:功能(结果){
log('ajax.success:',result);
参数成功({
});
},
错误:函数(er){
控制台日志(er)
}
});}