📅  最后修改于: 2022-03-11 15:02:06.655000             🧑  作者: Mango
var parts = window.location.search.substr(1).split("&");
var $_GET = {};
for (var i = 0; i < parts.length; i++) {
var temp = parts[i].split("=");
$_GET[decodeURIComponent(temp[0])] = decodeURIComponent(temp[1]);
}
console.log($_GET['query'])