[TYPO3-core] RFC #13461: bugfix: wrong image-path returned in class.t3lib_tceforms.php if TYPO3-source is symlinked (backend-redesign)

Stephan N Kellermayr stephan.kellermayr at t3x.at
Sun Mar 28 14:37:48 CEST 2010


yes! you are absolutely right!
...obviously i had a superfluous complex train of thoughts ;-)

thank you for your feedback!

updated now with a new (more simply and tested) patch.

best regards, Stephan



Steffen Gebert schrieb:
> Am 11.03.2010, 13:32 Uhr, schrieb Stephan N Kellermayr 
> <stephan.kellermayr at t3x.at>:
> 
>> bugtracker references:
>> http://bugs.typo3.org/view.php?id=13461
>>
>> branches:
>> trunk, current branch
>>
>> problem:
>> if an extension is installed in 'typo3conf/ext/' and overrides BE-icons,
>> the result of 't3lib_iconWorks::skinImg' (line:4008 in
>> class.t3lib_tceforms.php) is i.e.
>> "../typo3conf/ext/myextension/icons/gfx/i/pages.gif".
>> thats correct, but if we use a symlinked TYPO3-source we get an
>> incorrect path to the imagefile and so we do not get the correct
>> image-dimensions from 'getimagesize' (line:4010)!
>> ...
>> solution:
>> if 't3lib_iconWorks::skinImg' returns a filename beginning with '../'
>> resolve the absolute path to the file and then get the correct
>> image-dimensions.
>>
> 
> Hi Stephan,
> 
> thanks for your patch.
> 
> Please follow the Coding Guidelines.
> This line
>> if (substr($selIconFile,0,3)=='../')    {
> has to be
>> if (substr($selIconFile, 0, 3) == '../') {
> 
> Shouldn't it be possible without the if-clause?
> Just to have sth. like
>> getimagesize(t3lib_div::resolveBackPath(PATH_typo3 . $selIconFile));
> 
> This would simplify the code.
> 
> Bye
> Steffen

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: class.t3lib_tceforms.php.0013461.diff-v2
URL: <http://lists.typo3.org/pipermail/typo3-team-core/attachments/20100328/9b331fd2/attachment.txt>


More information about the TYPO3-team-core mailing list