window.location window的location对象 search 得到的是url中?部分 substr() 返回一个从指定位置开始的指定长度的子字符串 这里设置为1,是为了把url中的?号去掉