Project

General

Profile

Actions

Bug #38496

closed

Redirect of a shortcut does not take all URL parameters into account

Added by Helmut Hummel over 12 years ago. Updated about 7 years ago.

Status:
Closed
Priority:
Must have
Assignee:
Category:
-
Target version:
Start date:
2012-06-30
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.0
PHP Version:
5.3
Tags:
Complexity:
Is Regression:
No
Sprint Focus:
On Location Sprint

Description

Currently when a page is a shortcut, TYPO3 redirects to the page the shortcut points to.
But only configured linkVars and the type parameter are taken into account for generating the target link.
Any additional parameter that is appended to the URL of a shortcut page is discarded.

The solution is to just forward every GET parameter to the target page.


Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #34642: Shortcut redirects might loose linkVarsClosed2012-03-07

Actions
Actions #1

Updated by Helmut Hummel almost 12 years ago

  • Target version changed from 6.0.0-alpha3 to 6.0.1
Actions #2

Updated by Markus Klein over 10 years ago

  • Target version changed from 6.0.1 to next-patchlevel
  • Is Regression set to No
Actions #3

Updated by Sergio Catalá over 9 years ago

  • Assignee set to Susanne Moog

Susanne, we were talking yesterday about this issue. I am not able to patch it properly :(
Looking at this code under typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php file (lines from 3008 to 3012):

$type = GeneralUtility::_GET('type');
if ($type && MathUtility::canBeInterpretedAsInteger($type)) {
  $parameter .= ',' . $type;
}
$redirectUrl = $cObj->typoLink_URL(array('parameter' => $parameter));

I would replace for something like this:

$arguments = GeneralUtility::_GET();
unset($arguments['id']);
if (count($arguments)) {
  foreach ($arguments as $argument) {
    $parameter .= ',' . $argument;
  }
}

But as far as I can see, this is later used inside typolink function, that is a bit tricky.

Could you take a look?

Actions #4

Updated by Helmut Hummel over 9 years ago

imho it would be enough to add the config option "addQueryString" to the typolink call

Actions #5

Updated by Mathias Schreiber about 9 years ago

  • Target version deleted (next-patchlevel)
Actions #6

Updated by Susanne Moog about 8 years ago

  • Target version set to 8.4
  • Sprint Focus set to On Location Sprint
Actions #7

Updated by Tomita Militaru about 8 years ago

I am working on this one.

Actions #8

Updated by Gerrit Code Review about 8 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/49785

Actions #9

Updated by Gerrit Code Review about 8 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/49785

Actions #10

Updated by Gerrit Code Review about 8 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/49785

Actions #11

Updated by Gerrit Code Review about 8 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/49785

Actions #12

Updated by Gerrit Code Review about 8 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/49785

Actions #13

Updated by Tomita Militaru about 8 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #14

Updated by Markus Timtner almost 8 years ago

This fix is still not present in current v7 LTS branch!

Actions #15

Updated by Susanne Moog almost 8 years ago

This ticket will not be merged to the 7.6 LTS branch as it is a breaking change. See https://docs.typo3.org/typo3cms/extensions/core/8-dev/Changelog/8.4/Breaking-38496-AddAllParametersToAShortcutPage.html

If you need this fix, you could either upgrade to the 8 branch or patch your core version accordingly.

Actions #16

Updated by Markus Timtner almost 8 years ago

Hi Susanne,
thanks for the info. I wasn't aware of this being a breaking change...
I have patched my core version accordingly, didn't seem to have any negative side-effects.

Actions #17

Updated by Riccardo De Contardi about 7 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF