今天再做项目演示的时候,用的是ie浏览器报错404,项目都运行好久了,第一次用ie就这样了悲剧,贴下解决方法吧
function getContextPath() {
var pathName = document.location.pathname;
var index = pathName.substr(1).indexOf("/");
var result = pathName.substr(0,index+1);
return result;
}
window.location.href=getContextPath()+"/jurisdiction/jumpAddAccessPath.action;