设置或获取对象指定的文件名或路径。
window.location.pathname 设置或获取整个 URL 为字符串。 window.location.href 设置或获取与 URL 关联的端口号码。 window.location.port[……]

阅读全文