Use the document base url when resolving image URLs #10574
Labels
A-content/dom
Interacting with the DOM from web content
C-assigned
There is someone working on resolving the issue
E-less-complex
Straightforward. Recommended for a new contributor.
According to the specification (step 5.1), we need to be using the base URL. This means calling
document.base_url()
instead ofwindow.get_url()
as the code currently does.Code:
components/script/dom/htmlimageelement.rs
Test:
Visit this from a web server (eg.
python -m SimpleHTTPServer
) with aresources/
directory that contains animage.png
file.There does not appear to be an automated test for this yet, so we'll need to write a reference test! It belongs in
tests/wpt/web-platform-tests/html/semantics/embedded-content/the-img-element/
.The text was updated successfully, but these errors were encountered: