js获取url中参数
js方法
function getParameterValue(url) { var result = location.search.match(new RegExp("[\?\&]" + url + "=([^\&]+)","i")); if (result == null || result.length < 1){ return ""; }else { return result[1]; } }
js方法
function getParameterValue(url) { var result = location.search.match(new RegExp("[\?\&]" + url + "=([^\&]+)","i")); if (result == null || result.length < 1){ return ""; }else { return result[1]; } }