[TYPO3-team-core-v5] Getting rid of DIRECTORY_SEPARATOR reloaded

Malte Jansen mail at maltejansen.de
Sun Jul 27 23:50:51 CEST 2008


Hi Bastian!

Bastian Waidelich schrieb:
> Malte Jansen wrote:
>> IMO a path should always end with a slash
> 
> I don't really think so. It's easier to append a slash if needed, than 
> to crop a slash which is not needed. Besides, a path can also point to a 
> file ("/foo/bar/file.php").

So there two functions one for filepath and one for pathes. At the 
moment I generate a path and directly add filename to it.
But in other packages it might be different.
> 
> 
>> the pathes in the array should be UnixStyle
> 
> The thing is: you don't always know whether a path has to be transformed 
> or not. E.g. when you have to write a file to a path which the user can 
> set in the configuration.
> Sure, especially in the core packages we can take care of this and it's 
> done already in a lot of places. But a helper function might reduce 
> duplicated code and help other package developers.
> But you're right, at the cost of performance..

Perhaps these functions could be check with the FLOW3CGL, perhaps these 
function could also be over writen by FLOW3 like it should be for the 
"new" syntax...

Cheers,

Malte


More information about the TYPO3-team-core-v5 mailing list