Project

General

Profile

Actions

Bug #47844

closed

Query parameters of external link may get altered

Added by Flummi no-lastname-given almost 11 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Must have
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
Start date:
2013-05-02
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.0
PHP Version:
Tags:
Complexity:
medium
Is Regression:
Sprint Focus:

Description

Asuming the website is running on http://domain.tld
When now putting a link as external URL in the link picker e.g. http://domain.tld/index.php?id=2&foo=123
the rte adds all parameters except id another time to the url.

I.E:

<link http://domain.tld/index.php?id=1&foo=123&gt;test&lt;/link>

is changed after saving to:

<link http://domain.tld/index.php?id=1&foo=123,0,&foo=123&gt;test&lt;/link>

When saving another time, the RTE changes it again to:

<link http://domain.tld/index.php?id=1&foo=123,0,&foo=123,0,&foo=123,0,&foo=123&gt;test&lt;/link>

And so on until the links are very long and Typo3 crashes.

The problem seems to be in typo3/sysext/core/Classes/Html/RteHtmlParser.php
in line 680:

$href = ($attribArray['data-htmlarea-external'] ? $attribArray['href'] : $info['url']) . ($info['query'] ? ',0,' . $info['query'] : '');

I guess in line 1692 the class somehow assumes the link is a page link and sets the $info['query'] param, which then leeds to the error.

Actions

Also available in: Atom PDF