[TYPO3-core] RFC #9511: Bug: getHtmlTemplate should use resolveBackPath

Steffen Kamper info at sk-typo3.de
Wed Oct 8 10:11:42 CEST 2008


Hi,

Martin Kutschker schrieb:
> Steffen Gebert schrieb:
>> Hi!
>>
>> This is SVN patch request.
>>
>> Type: bug
>>
>> Branches: trunk, 4.2
>>
>> BT reference: http://bugs.typo3.org/view.php?id=9511
>>
>> Problem: 
>> getHtmlTemplate() in typo3/template.php calls getURL in the following way:
>> t3lib_div::getURL($this->backPath . $filename)
>>
>> For tt_news $this->backPath . $filename = "../../../../typo3/../typo3conf/ext/tt_news/mod1/mod_ttneypo3conf/ext/tt_news/mod1/mod_ttnews_admin.html" 
>> which can't be opened on some linux servers because of typo3/../
> 
> This has nothing todo with Linux but (firewall) restrictions that won't
> allow ../ in a URL.
> 
> If this is a real problem then I suggest to use
> t3lib_div::resolveBackPath() not in the call but only when
> $this->backPath is set. To be consistent this should be used verywhere
> in the code.
> 
> Masi

but i see the problem with all the extension using it and can't be 
changed all.
As extensions use syntax like
$this->doc->backPath = $BACK_PATH;
i would prefer a check in template where $this->backPath is used (own 
function) to change it with the t3liv_div-function (check for "typo3/.." 
before call)
so it's be converted one time and corrected for all usages

vg Steffen


More information about the TYPO3-team-core mailing list