Open Bug 1046488 Opened 11 years ago Updated 5 years ago

Copy/Cut/Paste with designMode on corrupts <img> and <a > paths (makes them absolute or removes them)

Categories

(Core :: DOM: Editor, defect, P5)

31 Branch
x86_64
All
defect

Tracking

()

People

(Reporter: danny0838, Unassigned)

Details

(Keywords: dataloss)

Attachments

(1 file)

Attached file test.html
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Firefox/31.0 (Beta/Release) Build ID: 20140716183446 Steps to reproduce: Test platform: Firefox 31.0 / Windows 7 SP1 1. Make a test file with designMode on (or use the attached test.html) 2. Open the file with Firefox 3. Select the content and copy/cut it: <p><a href="foo.html">foo</a></p> <p><img src="bar.jpg" alt="bar"></p> 4. Paste in the same page, select the result part and view its source Actual results: The pasted content is something like: <p><a>foo</a></p> <p><img src="file:///D:/blah/blah/blah/bar.jpg" alt="bar"></p> The href attribute of the <a> node is missing. The src attribute of the <img> node becomes absolute. Expected results: The href attribute of the <a> node should not missing. The src attribute of the <img> node should not be changed.
Additionally, href missing of <a> nodes only happens when the file is in the local file system (protocol file://). If the file is on the web (protocol http://), the href attribute will become absolute, as the <img> nodes do.
Reproduced with firefox-31.0.en-US.linux64 2014-08-04-03-02-05-mozilla-central-firefox-34.0a1.en-US.linux-x86_64
Status: UNCONFIRMED → NEW
QA Whiteboard: [bugday-20140804]
Component: Untriaged → Editor
Ever confirmed: true
Keywords: dataloss
OS: Windows 7 → All
Product: Firefox → Core
Summary: Copy/Cut/Paste with designMode on corrupts <img> and <a > paths → Copy/Cut/Paste with designMode on corrupts <img> and <a > paths (makes them absolute or removes them)

Bulk-downgrade of unassigned, >=5 years untouched DOM/Storage bugs' priority and severity.

If you have reason to believe this is wrong, please write a comment and ni :jstutte.

Severity: normal → S4
Priority: -- → P5
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: