window.location各属性的值


window.location各属性的值

window.location.href            "https://i.cnblogs.com/EditPosts.aspx?opt=1"

window.location.protocol      "https:"

window.location.host           "i.cnblogs.com"

window.location.port            返回端口号

window.location.pathname    "/EditPosts.aspx"

window.location.search         "?opt=1"

window.location.hash            返回锚点     #test


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM