Open
Bug 893605
Opened 12 years ago
Updated 3 years ago
History API not working properly in XSLT
Categories
(Core :: XSLT, defect)
Tracking
()
NEW
People
(Reporter: contacto, Unassigned)
Details
Attachments
(1 file)
3.82 KB,
application/octet-stream
|
Details |
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:21.0) Gecko/20100101 Firefox/21.0 (Beta/Release)
Build ID: 20130514193536
Steps to reproduce:
To see the bug: http://share.nekmo.com/firefox_bug
1. The page starts as "http://share.nekmo.com/index.xml"
2. Using History API URL is changed to "http://share.nekmo.com/subdir/index.html"
3. An image with relative link to "image.png" is added to the document.
Actual results:
4. The image points to "http://share.nekmo.com/image.png".
Expected results:
5. The image should be directed to: "http://share.nekmo.com/subdir/image.png".
In chromium works well. In Firefox with HTML also.
Comment 2•12 years ago
|
||
nsImageLoadingContent::LoadImage ends up calling nsIContent::GetBaseURI (via http://mxr.mozilla.org/mozilla-central/source/content/base/src/nsImageLoadingContent.cpp#1009), which in turns calls nsDocument::GetDocBaseURI (http://mxr.mozilla.org/mozilla-central/source/content/base/src/FragmentOrElement.cpp#269), which will always return an explicit base URI over the current document one. PushState ends up calling nsDocument::SetDocumentURI which sets mDocumentURI, but XMLDocument explicitly sets a base URI (http://mxr.mozilla.org/mozilla-central/source/content/xml/document/src/XMLDocument.cpp#146). That's my guess, at least.
![]() |
||
Comment 3•12 years ago
|
||
Ah, hmm. I wonder whether we should avoid setting the base URI there if it's equal to the document URI...
Flags: needinfo?(bugs)
Updated•12 years ago
|
Flags: needinfo?(justin.lebar+bug)
Comment 4•12 years ago
|
||
But are there valid cases when we should have baseuri explicitly set? Anyhow, sounds like jdm is correct and XSLT shouldn't set baseuri by default.
Component: DOM → XSLT
Flags: needinfo?(bugs)
Updated•12 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•