gpt4 book ai didi

javascript - 如何防止此广告网络 http 请求?以及如何插入请求?

转载 作者:塔克拉玛干 更新时间:2023-11-01 21:28:43 24 4
gpt4 key购买 nike

我有一个带有 javascript 的简单网页,它向服务器发送各种请求。但在这之间,我收到来 self 的网站的网络请求和我不负责的网络请求。

我的 HTML 页面

<div class="container">
<div class="row">
<div>
<div class="row">
<div class="col-md-6 ">
<div class="form-group">
<label for="inputDate" class="col-sm-1 control-label">Date</label>
<div class="col-sm-6">
<input type="date" class="form-control" id="inputDate" name="inputDate" placeholder="Date" required>
</div>
<button type="submit" class="btn btn-primary get" onclick="getdata()">Get</button>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="panel panel-default">
<!-- Default panel contents -->
<div class="panel-heading">Dispatch Overview</div>
<div class="panel-body">
<p>...</p>
</div>



<!-- Table -->
<table id="dispatchOverviewTable" class="table table-striped">
<thead>
<tr>
<th>Sr.Nos</th>
<th>Item</th>
<th>Qty</th>
<th>Kg</th>


</tr>
</thead>
<tbody>

</tbody>
</table>


<!-- Table -->
<table id="dispatchDetailTable" class="table table-striped">
<thead>
<tr>
<th>Sr.Nos</th>
<th>Id</th>
<th>Item</th>
<th>Qty</th>
<th>Kg</th>
<th>Account</th>

</tr>
</thead>
<tbody>

</tbody>
</table>
</div>
</div>

我的 Javascript:

 function getdata()
{
var totalFeed;
console.log('in function getdata');
var data=$('#inputDate').val();
console.log(data);
$.get( '/index.php/async/getDispatchDetails/'+data,function( data ) {

console.log(data.dispatchdata);
console.log(data.itemdata);

$('#dispatchDetailTable > tbody > tr').remove();

for (var i = 1; i <= data.dispatchdata.size; i++) {
console.log("inside for loop");
var row = "";
row = "<tr><td>" + i + "</td><td>"+
data.dispatchdata[i].dispatchid +"</td><td>"+
data.dispatchdata[i].itemname +"</td><td>"+
data.dispatchdata[i].quantity + "</td><td>" +
data.dispatchdata[i].weight + "</td><td>" +
data.dispatchdata[i].accountname + "</td><td>" +

"</td></tr>";
$('#dispatchDetailTable > tbody:last').append(row);

}



});
}

我的浏览器控制台: 未知部分

 *************** Muted gameContent
VM16571:1 [Wed Jul 8 17:10:51 GMT+0530 2015] (#0): event:[Event type="complete" bubbles=false cancelable=false eventPhase=2]
vpc.xml:1 GET http://vpc.altitude-arena.com/vpc.xml?uid=1jmf6b3e9c817755&page_url=http%3A…a_file_title=[REPLACE]&media_description=[REPLACE]&media_file_id=[REPLACE] 404 (Not Found)
vast.yashi.com/crossdomain.xml:1 GET http://vast.yashi.com/crossdomain.xml net::ERR_EMPTY_RESPONSE
VM16601:1 [Wed Jul 8 17:10:55 GMT+0530 2015] (#0): adLoaded[LiveRailEvent type="initComplete" adMap=[object Object]]
VM16602:1 [Wed Jul 8 17:10:55 GMT+0530 2015] (#0): START
vpc.xml:1 GET http://vpc.altitude-arena.com/vpc.xml?uid=ql6df2bd02fd5b45&page_url=[REPLAC…a_file_title=[REPLACE]&media_description=[REPLACE]&media_file_id=[REPLACE] 404 (Not Found)
VM16710:1 [Wed Jul 8 17:11:15 GMT+0530 2015] (#0): destroy: false
adaptvInfo.js:1 Uncaught Error: Error: An invalid exception was thrown.window.adaptvInfo.fraudScoreCallback @ adaptvInfo.js:1window.(anonymous function) @ adaptvInfo.js:1R.stringToFn @ bapi?anid=6058&ias_callback=adaptv1436355672623&pubid=b4.epicplay.com&placementId=498506:194na.wrap.window.(anonymous function) @ bapi?anid=6058&ias_callback=adaptv1436355672623&pubid=b4.epicplay.com&placementId=498506:174(anonymous function) @ dbapi?ias_callback=__IntegralAS_371ff0f1256611e58a6b002590882ecc_1781&anid=6058&pubid=b4.epicplay.c…:1
vast-rtb.js?1:1 allVastAdsCompleted: NaN; Load Errors: 0

最佳答案

这与您的网站无关,但与您操作系统上运行的某些插件/应用程序有关,如果您愿意,它是广告软件或病毒,可能是安装了一些免费软件程序(如 youtube 到 mp3 转换器或类似软件)的结果。

为了确认这一点,我建议您在虚拟机或另一台计算机上测试您的网站。

关于javascript - 如何防止此广告网络 http 请求?以及如何插入请求?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31292064/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com