[BUGFIX] RTE: Correct behavior on empty textfield in Firefox 50/49150/8
authorAndreas Fernandez <a.fernandez@scripting-base.de>
Thu, 21 Jul 2016 12:14:31 +0000 (14:14 +0200)
committerJigal van Hemert <jigal.van.hemert@typo3.org>
Tue, 26 Jul 2016 14:35:56 +0000 (16:35 +0200)
commitb442a8ddd7c1770a8c9d02ad825338d89a848c0f
treef5ff2e8fa5b73ecbaf1c48a5ac05881b963b6420
parent015e8cd9bd0f26bc6fbf5c93d9941980780b5fdf
[BUGFIX] RTE: Correct behavior on empty textfield in Firefox

With Firefox, the RTE produces several JavaScript errors if the textfield
is empty. The issue is that on Firefox it's tried to access the parent
node of the html tag which is nonsense.

Some regular expressions and an additional 'undefined' check are added
to fix this wrong behavior.

Resolves: #77191
Releases: master, 7.6
Change-Id: I617bdb6415c0468894aee08101c9d26cb790a077
Reviewed-on: https://review.typo3.org/49150
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Bamboo TYPO3com <info@typo3.com>
Tested-by: Riccardo De Contardi <erredeco@gmail.com>
Reviewed-by: Jigal van Hemert <jigal.van.hemert@typo3.org>
Tested-by: Jigal van Hemert <jigal.van.hemert@typo3.org>
typo3/sysext/rtehtmlarea/Resources/Public/JavaScript/HTMLArea/DOM/DOM.js
typo3/sysext/rtehtmlarea/Resources/Public/JavaScript/HTMLArea/DOM/Selection.js
typo3/sysext/rtehtmlarea/Resources/Public/JavaScript/Plugins/BlockElements.js
typo3/sysext/rtehtmlarea/Resources/Public/JavaScript/Plugins/DefinitionList.js
typo3/sysext/rtehtmlarea/Resources/Public/JavaScript/Plugins/MicrodataSchema.js