function getParam(param){
var url = window.location.href;
var params = url.split('?')[1];
var paramArr = params.split('&');
var paramObj = {};
for(var i=0; i<paramArr.length; i++){
paramObj[paramArr[i].split('=')[0]] = paramArr[i].split('=')[1]
}
return paramObj[param];
}
获取url参数
最新推荐文章于 2020-12-28 21:19:52 发布