[TYPO3-dam] dam_index external tools
Francois Suter
fsuter at cobweb.ch
Wed Apr 16 15:07:22 CEST 2008
Hi,
> Thank for your answer, I thought nobody would answer me :-)
Well, that happens sometimes. As frustrating as it might be, this is
open source... Most of the time you *do* get an answer.
> I decided to track this problem down, wherever it would get me and
> finally got the answer:
Wise decision :-)
> 1) the tests in both classes I described above and located in t3lib_dir
> do checks using the "@" prefix to functions is_dir() and
> is_executable(). That is any warning (such as the openbase_dir
> restriction) will not be put in the PHP error log. I think this is a
> problem that should be tackled with as it is complicated to track down
> such issues.
The @ prefix must not be removed. However, the error should be checked
for. The thing is that we can't afford to have random PHP messages
popping all over the place. So the use of @ is good. But obviously
situations where error can occure should be checked for and caught.
As a case in point I was recently developing a utility to write to the
DAM after receiving a POST request from a remote server. I stumble on a
call to a PHP function without @ prefix. The problem is that the PHP
error message was sent back in my response, which was undesirable. Thus
the @ prefix is good, but errors must still be caught and handled
appropriately of course.
> May I contribute to enhance this base class?
Of course, core-team mailing list is open to everyone who comes up with
a nice patch :-)
> Do someone disagree with my
> point of view? And if so, why?
See above.
Cheers
--
Francois Suter
Cobweb Development Sarl - http://www.cobweb.ch
More information about the TYPO3-project-dam
mailing list