小编Dem*_*usa的帖子

我想将 API 密钥附加到我的 URL 以访问数据库,问题是将它附加到文件名

我想将 API 密钥附加到我的 URL 以访问数据库,问题是将它附加到文件名

var pivot = new WebDataRocks({
    container: "#wdr-component",
    toolbar: true,
    report: {
        dataSource: {
            filename: "https://testing-195b.restdb.io/rest/customerdata"
        }
    }
});
Run Code Online (Sandbox Code Playgroud)

此代码适用于控制台

  var settings = {
    "async": true,
    "crossDomain": true,
    "url": "https://testing-195b.restdb.io/rest/customerdata",
    "method": "GET",
    "headers": {
      "content-type": "application/json",
      "x-apikey": "60c8b39ee2c96c46a2463581",
      "cache-control": "no-cache"
      
    }
  }
  
  $.ajax(settings).done(function (response) {
    console.log(response);
    
  });
Run Code Online (Sandbox Code Playgroud)

html javascript backend api-key webdatarocks

-1
推荐指数
1
解决办法
74
查看次数

标签 统计

api-key ×1

backend ×1

html ×1

javascript ×1

webdatarocks ×1