Closed Bug 292754 Opened 19 years ago Closed 19 years ago

[FIXr]A number of URL properties of HTML elements are not resolved (e.g. cite of ins)

Categories

(Core :: DOM: Core & HTML, defect, P2)

defect

Tracking

()

RESOLVED FIXED

People

(Reporter: minghong, Assigned: bzbarsky)

Details

Attachments

(2 files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.7) Gecko/20050414 Firefox/1.0.3
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.7) Gecko/20050414 Firefox/1.0.3

Related URLs are not resolved to full URL for a number of properties included in
DOM HTML. These include:
- cite of ins/del;
- action of form;
- src of input; and
- useMap of a number of elements like image and object.

See also http://en.wikipedia.org/wiki/Comparison_of_layout_engines_%28DOM%29 for
a complete list of such attributes.

Reproducible: Always

Steps to Reproduce:
1. Get the property value of such attribute

Actual Results:  
Same as that returned from getAttribute().

Expected Results:  
Should be treated as URL, e.g. "a/b/c" -> "http://localhost/a/b/c"
Attached file Testcase
I believe this is a duplicate of an invalid bug. Why should attribute values be
resolved?
Could you quote the part that says UAs need to resolve the URIs?
By the way, note that I said "property", not "attribute". They are 2 different
things. Property should be resolved, but attribute shouldn't.
In Mozilla, if an attribute (e.g. href) is treated as a URI, its corresponsing
property (e.g. this.href) would return the resolved URI. Try "href" of a/link,
"cite" of q/blockquote.

I can't found where the spec said so, but it seems to be the right treatment to
URI attributes.
Please do NOT test DOM bugs in 1.7 builds.  Those builds are over a year old in
terms of DOM support at this point.

In current builds, most properties defined as URIs in the DOM spec are resolved
(in particular the action of forms and the src of inputs).

Del and Ins do need to be fixed (and I'll attach a patch to do that).  The
behavior for usemap is not clear, since that's not defined as a URI in the DOM
spec.  There's another bug with some discussion on what to do with properties
that are sort of URIs but not defined as such in the DOM (and this bug may be
invalid; I can't recall).  db48x, I remember you were poking at that; do you
recall the bug#?  Or was it just bug 213701?
Attached patch Fix for ins/delSplinter Review
Assignee: general → bzbarsky
Status: UNCONFIRMED → ASSIGNED
Attachment #182513 - Flags: superreview?(jst)
Attachment #182513 - Flags: review?(jst)
OS: Windows 2000 → All
Priority: -- → P2
Hardware: PC → All
Summary: A number of URL properties of HTML elements are not resolved (e.g. cite of ins) → [FIX]A number of URL properties of HTML elements are not resolved (e.g. cite of ins)
Comment on attachment 182513 [details] [diff] [review]
Fix for ins/del

r+sr=jst
Attachment #182513 - Flags: superreview?(jst)
Attachment #182513 - Flags: superreview+
Attachment #182513 - Flags: review?(jst)
Attachment #182513 - Flags: review+
Summary: [FIX]A number of URL properties of HTML elements are not resolved (e.g. cite of ins) → [FIXr]A number of URL properties of HTML elements are not resolved (e.g. cite of ins)
Comment on attachment 182513 [details] [diff] [review]
Fix for ins/del

Simple fix to an HTML property that got missed when I did the sweep of DOM URI
properties.
Attachment #182513 - Flags: approval1.8b2?
Attachment #182513 - Flags: approval1.8b2? → approval1.8b2+
Fixed (for ins/del; as I said earlier the behavior for usemap seems to be
correct per the DOM spec).
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Component: DOM: HTML → DOM: Core & HTML
QA Contact: ian → general
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: