[TYPO3-core] RFC: #3819: t3lib_div::getIndpEnv('TYPO3_DOCUMENT_ROOT') delivers wrong value in Backend

Jigal van Hemert jigal at xs4all.nl
Sun Aug 8 18:15:34 CEST 2010


Hi,

On 8-8-2010 18:00, Steffen Kamper wrote:
> after discussing this with Susanne, the original purpose of this var is
> to give the web root, not the TYPO3 root. The problem of the bug report
> is only wrong usage, same is done in core.

I was already writing a response in the same line :-)

Anyway, some of the changes in the core in version 2 of your patch are 
incorrect:

- $d = 
dir(t3lib_div::getIndpEnv(TYPO3_DOCUMENT_ROOT).'/'.$fieldSetup['uploadfolder']);
+ $d = PATH_site . $fieldSetup['uploadfolder'];

The original line also did dir() command, which is used in the next lines:

	while (false !== ($entry = $d->read())) {
		if ($entry == '.' || $entry == '..') {

This is the case in both class.t3lib_fullsearch.php and 
class.t3lib_querygenerator.php

+1 if you change these two things.

-- 
Jigal van Hemert
skype:jigal.van.hemert
msn: jigal at xs4all.nl
http://twitter.com/jigalvh


More information about the TYPO3-team-core mailing list