截取QueryString 通过截取?和& 小写

时间:2022-07-21 05:34:52

$(function () {
var url = location.href.replace("#", "");
var paraString = url.substring(url.indexOf("?") + 1, url.length).split("&");
for (var i = 0; j = paraString[i]; i++) {
Cmd.Entity.QueryString[j.substring(0, j.indexOf("=")).toLowerCase()] = j.substring(j.indexOf("=") + 1, j.length);
}