Bug 183427 - Pasting from an html file file relative anchors imports the whole file and breaks all anchors
Summary: Pasting from an html file file relative anchors imports the whole file and br...
Status: REOPENED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EPF (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: epf.tool-inbox CLA
QA Contact: wang jun CLA
URL:
Whiteboard: RTE
Keywords:
Depends on:
Blocks:
 
Reported: 2007-04-20 14:08 EDT by Peter Haumer CLA
Modified: 2023-02-16 16:16 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Haumer CLA 2007-04-20 14:08:10 EDT
Paste from an html file that has a lot of relative anchors in this format "#name". It imports the whole file and places it in the resources directory. It then changes all the anchors to "./resources/file#name".  When you now publish it opens that files instead of "jumping" within the same page which is the intended behavior. The file of course might be out of sync with the pasted version as well as has not the RMC styles.
Comment 1 Jeff Hardy CLA 2007-04-20 19:19:39 EDT
Changing priority - this is hardly a showstopper
Comment 2 Jeff Hardy CLA 2007-05-04 01:18:00 EDT
Fixed - RTE should preserve the links to anchors
Comment 3 wang jun CLA 2007-06-09 02:31:16 EDT
Fix is verified on Daily build 20070608-0000 and closed.
Comment 4 Peter Haumer CLA 2007-08-30 16:12:49 EDT
The pasted html is now correct when pasting from a web browser, but it still creates a copy of the source html file in the ./resources directory.  This file must not be there as it is not used and might confuse the user. 

The paste does not work when pasting from html editors such IBM Rational Software Architect's HTML editor's design view or Microsoft Expression Web.  It then still changes the anchors to this "./resources/file#name"; just a before the fix.
Comment 5 Bingxue Xu CLA 2007-08-30 19:42:04 EDT
we will further improve the RTE functionality in the next release by accommodating more 3rd party tools as the source of copying. 

The creation of the extra file is due to the self-reference link like href"#ref" in the copied contents. The current parsing code will treat it as a ligimate refereneced resource, and copy it. Making changes on this logic requires the underlying JavaScript and Java code changes.