0
说明一些JavaScript代码在Chrome中,我面临着接下来的事情:( “?mail.fpp A = 123sd” 之称)的document.BaseURI行为
如果通到xhr.open相对URL一样此
xhr.open("post", "mail.fpp?a=123sd", true)
请求将在
https://www.somedomain.com/mail/mail.fpp?a=123sd
被发送的所有非常愉快,但document.URI(和document.location.toString())具有值
https://www.somedomain.com/default.aspx?id=12345
我注意到,基本URI具有价值
https://www.somedomain.com/mail/
但docs document.BaseURI只读根据。
为什么document.URI(或document.location.toString())不等于document.BaseURI?什么会导致这种不平等?
您的HTML文档在任何地方都有[' '](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base)元素吗? –
apsillers