var urlPath = window.document.location.href; //浏览器显示地址 http://10.15.5.83:5555/ISV/demo.aspx?a=1&b=2
var docPath = window.document.location.pathname; //文件在服务器相对地址 /ISV/demo.aspx
var index = urlPath.indexOf(docPath);
var serverPath = curWwwPath.substring(0, index);//服务器地址 http://10.15.5.83:5555