判断请求头中是否含有某属性来判断是否是ajax请求

qianbaoyi66250 22 0 PDF 2020-12-17 05:12:57

代码如下: <html> <head> [removed] function cl() { var xmlhttp; if (window.XMLHttpRequest) { xmlhttp=new XMLHttpRequest(); } else { xmlhttp=new ActiveXObject(“Microsoft.XMLHTTP”); } xmlhttp.open(“POST”,”ajax2.html”,true); xmlhttp.setRequestHeader (“Content-Type”,”application/x- www-f

用户评论
请输入评论内容
评分:
暂无评论