[TYPO3-core] FYI: Fixed bug #4121: Pasting content on htmlArea RTE moves cursor to the top of the text
Stanislas Rolland
typo3 at sjbr.ca
Sat Mar 1 04:17:05 CET 2008
FYI: The attached SVN patch was committed.
Type:
Bugfix
Problem:
When content is pasted in the RTE and the html cleaning feature is
enabled (enableWordClean = 1) and the use of the TYPO3 html parser is
configured (enableWordClean.HTMLparser = 1), the resulting content of
the RTE is sent to the server to be parsed and cleaned. On reception of
the response, the editing area of the RTE is reset with the cleaned
content. In this process, the cursor position is completety lost.
Solution:
The attached patch inserts in the content a bookmark that will keep the
position of the cursor. In gecko browsers, the bookmark takes the form
of a span element with a random id, a style attribute with display set
to none, and a custom attribute named HTMLArea_bookmark set to true. On
reception of the response, if the span element was not washed away by
the html parser, the cursor is restored to its original position and the
bookmark is removed. Tested in Mozilla 1.7, FF2, FF3, IE7, Safari3 and
Opera9.5.
Bugtracker references:
http://bugs.typo3.org/view.php?id=4121
Branch:
TYPO3_4-2
Regards,
Stanislas
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: rtehtmlarea_bugfix_4121.patch
Url: http://lists.netfielders.de/pipermail/typo3-team-core/attachments/20080229/de800953/attachment.txt
More information about the TYPO3-team-core
mailing list