[TYPO3-core] RFC #8580: Feature: New hooks for class.t3lib_extfilefunc.php

Martin Kutschker martin.kutschker-no at spam-blackbox.net
Tue Jun 3 09:50:00 CEST 2008


Oliver Hader schrieb:
> Hi Custos,
> 
> Custos Ostii schrieb:
>> This is an SVN patch request.
>>
>> Type: New feature
>>
>> Bugtracker references:
>> http://bugs.typo3.org/view.php?id=8580
>>
>> Branches:
>> TYPO3_4-2 and trunk
>>
>> Problem:
>> There isnt any way to fire events on file functions
>>
>> Solution:
>> New hooks for class.t3lib_extfilefunc.php With these hooks you could, 
>> for example, sync another filesystem on demand (I just did it with a 
>> S3 storage)   
>>
>> Notes:
>> It needs even more hooks in each function, but time to time
> 
> I have a similar patch in the pipeline. Thus, I'm going to have a look 
> on your work tomorrow and maybe merge things together. But, this feature 
> can only go into Trunk (for TYPO3 4.3).

But please be careful. Hooks are powerful, but if too many (non-API) 
functions have a hook, TYPO3 becomes even more inflexible because of 
compatibility issues.

So I think a hook should only be added if it's of general purpose and 
crafted in a way that it can possibly used in more ways than the 
original idea covered. Especically think about the arguments the hook 
takes. It's annyoing if we have to add another hook becaue the first one 
didn't have eg some important state information availabale that for some 
reason the hook creator didn't needed.

Masi


More information about the TYPO3-team-core mailing list