var url1= "../../Test1.aspx?para=" + escape(‘中文参数‘); var url2 = "....."; urlJS.js 获取该参数 var para = getValueString("para"); function getValueString(name) { var url = location.href; //var url = decodeURI(url); var url = decodeURI(unescape(url)); // var url = decodeURIComponent(unescape(unescape(url))); var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)"); var r = url.substr(1).match(reg); if (r != null) return unescape(r[2]); return null; }
时间: 2024-10-12 19:53:53