既是window对象的属性,也是document的属性
so window.location==document.location
location对象保存着当前文档的信息还可以将url解析为独立的片段