Closed Bug 334648 Opened 19 years ago Closed 3 years ago

Automatic absolute to relative URL conversion when pasting to designMode fails if GET parameters contain slashes

Categories

(Core :: DOM: Editor, defect)

1.8 Branch
x86
Windows XP
defect
Not set
major

Tracking

()

RESOLVED INCOMPLETE

People

(Reporter: dbw2, Unassigned)

References

Details

User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 2.0.50727; .NET CLR 1.1.4322) Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) Gecko/20051111 Firefox/1.5 This bug is related to 290740 and 295930, but somewhat more bugly. First, specifications state that forward slashes are allowed in GET parameters (ie http://www.somesite.com/page.html?getvar=/some/var/with/slashes). If such a page contains an iframe in designmode, any code dragged into it or pasted from the same site which contains absolute urls will get an incorrect absolute to relative transformation, treating all slashes as if they are part of the real path. In this case, pasting in <a href="http://www.somesite.com/images/image.gif>...</a> will result in <a href="../../../../../images/image.gif">...</a>, an obviously incorrect result, with a '../' for every false and real path member. Whatever code is making this transformation is making a fatal assumption about the meaning of slashes in the current pages complete href. Reproducible: Always Steps to Reproduce: 1.Go to a page with a designmode iframe which also has a get parameter with slashes. 2.Paste or drag in code with an absolute url referring to somewhere on the same site. Actual Results: The slashed get parameter is treated as part of the path. Expected Results: The pasted URL will point to the correct location. As others have stated in the bugs mentioned above, I believe we would be better off not doing this transformation at all, pasting in the URL exactly as given, and relying on the user or his/her editing agent to sort it out. At the very least the transformation should produce the correct result, though.
Assignee: nobody → mozeditor
Component: General → Editor
Product: Firefox → Core
QA Contact: general
Summary: Automatic absolute to relative URL conversion when pasting to design mode fails if GET parameters contain slashes → Automatic absolute to relative URL conversion when pasting to designMode fails if GET parameters contain slashes
Version: unspecified → 1.8 Branch
QA Contact: editor
Assignee: mozeditor → nobody
Blocks: 424615

Marking this as Resolved > Incomplete since the last activity on this issue was 16 years ago and it might not be relevant anymore.
Feel free to re-open if the issue is still reproducible on your end in the latest FF versions.

Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.