Project

General

Profile

Actions

Bug #18032

closed

using addQueryString couses wrong cHash on pages with no query string

Added by Vladimir Podkovanov almost 17 years ago. Updated about 16 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2008-01-21
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.1
PHP Version:
4.3
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

After moving site to new server I've find out that some pages does not getting cached anymore though on previous server they does. Then I traced it to next:
- lets say you use typolink function with addQueryString and additionalParams properties set
- then the conf getting processed in class.tslib_content.php::typoLink
- there is a call to class.tslib_content.php::getQueryArguments, BUT if the current page has no query string then you got only '&' string out of the method
- and after this it is glued with additionalParams string so you get string like this '&&param=value...'
- then it is passed to t3lib_div::cHashParams and becouse of double ampersands we get one empty key with empty value in result array
- and then it is passed to t3lib_div::shortMD5(serialize(...))
- and then we GOT WRONG cHash because that '&&' coused an empty key/value in cHashParams array

looks like PHP ver 4.4.7 that I got on new server serializes that empty value in array and an old version does not so the bug revealed only after moving

PHP version 4.4.7
(issue imported from #M7230)


Files

bug_0007230.diff (748 Bytes) bug_0007230.diff Administrator Admin, 2008-01-21 02:11
Actions

Also available in: Atom PDF