Project

General

Profile

Actions

Bug #59302

closed

JavaScript Error with userLinks in RTE

Added by Robert Vock over 10 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2014-06-03
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
Is Regression:
Yes
Sprint Focus:

Description

If using custom user links in the RTE, you get a JavaScript error, if you click any link with a target.

Page TS Config:

RTE.default.userLinks.10 {
    url = http://www.typo3.org
    target = _blank
    description = TYPO3 Homepage
}

Offending Line:

# typo3/sysext/rtehtmlarea/Classes/BrowseLinks.php:613
if (isset($v[$k2i . '.']['target'])) {
    $onClickEvent .= 'TYPO3\\CMS\\Recordlist\\Browser\\ElementBrowser_setTarget(\'' . $v[($k2i . '.')]['target'] . '\');';
}

The Javascript function is named browse_links_setTarget.

The feature is also badly documented:
http://docs.typo3.org/TYPO3/extensions/rtehtmlarea/Configuration/PageTsconfig/userLinks/Index.html
There is no info what userLinks are good for or how they look. For those who want to know how they look, I've attached a screenshot.

The Bug was introduced in 4612259a457f43edaf723e1f4a8ef4ae89d00a34 when namespaces were introduced, so it is quite a long time ago.

Maybe it could be removed, because it's not well documented, buggy and I don't see a point in providing a set of fixed links :)


Files

Actions

Also available in: Atom PDF