当前位置:网站首页>Get parameters on link
Get parameters on link
2022-06-13 04:18:00 【Twinkle, twinkle, twinkle, twinkle, twinkle, twinkle, twinkle, 】
getParams(url){
let str=url.split('?')[1]//? What's behind the number is what we need name=quan&age=21&sex=1
let arr=str.split('&')//["name=quan", "age=21", "sex=1"]
let obj={}
for(let i=0;i<arr.length;i++){
let key=arr[i].split('=')//["name", "quan"] ["age", "21"] ["sex", "1"]
obj[key[0]]=key[1]
}
return obj
},边栏推荐
- EIA map making - data processing + map making
- String full summary
- VGA display based on de2-115 platform
- [MySQL] index and transaction
- 剑指 Offer 11. 旋转数组的最小数字-二分查找
- Redis-HyperLogLog-基数统计算法
- MCU: pcf8591 hardware interface
- 在线音频调节技术汇总
- Lambda termination operation Max & min
- 【LeetCode】860. Change with lemonade (2 brushes for wrong questions)
猜你喜欢

120. 三角形最小路径和-动态规划

Uni app dynamic add style dynamic bind background image invalid

Principle, composition and functions of sensors of Dajiang UAV flight control system
![[web] cookies and sessions](/img/00/b10a9f4ae918afe5d032a9af20a49c.png)
[web] cookies and sessions

Ladder race

Real time requirements for 5g China Unicom repeater network management protocol

高等数学(第七版)同济大学 习题1-3 个人解答

Redis data persistence

R: Employee turnover forecast practice

SCM signal generator program
随机推荐
十亿数据量 判断元素是否存在
SCM: introduction to Modbus communication protocol
环评图件制作-数据处理+图件制作
120. 三角形最小路径和-动态规划
ROS中的msg消息
Single chip microcomputer: d/a output
Redis hyperloglog cardinality statistics algorithm
剑指 Offer 11. 旋转数组的最小数字-二分查找
This Sedata uses multiple methods to dynamically modify objects and values in arrays. Object calculation properties
[test development] advanced part - Classification of various test technologies
Interpretation of usb-if bc1.2 charging protocol
Manage PC startup items
建模杂谈系列143 数据处理、分析与决策系统开发的梳理
PAT 1054 The Dominant Color
Lambda end operation find and match allmatch
解答私信@田田WX //2022-6-12 C语言 51单片机LED模拟交通灯
Uni app dynamic add style dynamic bind background image invalid
[test development] file compression project practice
【ZeloEngine】本地化流程/ImGui中文化
Configuration and practice of shardingsphere JDBC sub database separation of read and write