标签:code func dex string url fun substr log col
let obj=turnUrl(url); console.log(obj); function turnUrl(url){ let num = url.indexOf("?"); url = url.substring(num+1); let arr = url.split("&"); let obj={}; for(let i=0;i<arr.length;i++){ let newArr=arr[i].split("="); obj[newArr[0]]=newArr[1]; } return obj; }
标签:code func dex string url fun substr log col
原文地址:https://www.cnblogs.com/13330893721zhy/p/11512327.html