这是jjava代码
@At
@Ok("jsp:website.schoolmanagement")
public void SchoolmanagementSvw() {
}
这是js代码,usr = “SchoolmanagementSvw”
function addTab(title, url){
var jq = top.jQuery;
if (jq('#tabs').tabs('exists', title)){
jq('#tabs').tabs('select', title);
} else {
var content = '<iframe scrolling="auto" frameborder="0" src="'+url+'" style="width:100%;height:100%;"></iframe>';
jq('#tabs').tabs('add',{
title:title,
content:content,
closable:true
});
}
}
用的是easyui 的 tabs 。然后chrome 的请求里会产生两个请求,一个红的,一个黑的。
红的请求出错
Request URL:http://127.0.0.1:8080/mds/SchoolmanagementSvw
Referrer Policy:no-referrer-when-downgrade
Request Headers
Provisional headers are shown
Referer:http://127.0.0.1:8080/mds/SigninSvw
Upgrade-Insecure-Requests:1
User-Agent:Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.110 Safari/537.36
黑的就正常,页面可以正常访问。
Request URL:http://127.0.0.1:8080/mds/SchoolmanagementSvw
Request Method:GET
Status Code:200 OK
Remote Address:127.0.0.1:8080
Referrer Policy:no-referrer-when-downgrade
Response Headers
view source
Content-Length:7334
Content-Type:text/html;charset=UTF-8
Date:Fri, 31 Mar 2017 02:08:17 GMT
Server:Apache-Coyote/1.1
X-Powered-By:nutz/1.r.60 <nutzam.com>
Request Headers
view source
Accept:text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Accept-Encoding:gzip, deflate, sdch, br
Accept-Language:zh-CN,zh;q=0.8
Cache-Control:no-cache
Connection:keep-alive
Cookie:JSESSIONID=909E0674F386042153126CA501D2A29D
Host:127.0.0.1:8080
Pragma:no-cache
Referer:http://127.0.0.1:8080/mds/SigninSvw
Upgrade-Insecure-Requests:1
User-Agent:Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.110 Safari/537.36
不理解为什么