[TYPO3-dev] Error-Messages in ListView of new Backend

Steffen Kamper steffen at sk-typo3.de
Fri Apr 11 12:52:42 CEST 2008


"Stefan Geith" <typo3dev2008.nospam1 at geithware.de> schrieb im Newsbeitrag 
news:mailman.4988.1207910715.3430.typo3-dev at lists.netfielders.de...
> Hi Devs,
>
> I just made a local copy of one of my sites, and forgot to copy the 
> tt_news extension (that is used on this site) to the ext-folder.
>
> This lead me to an error-message:
> In Listmode I got this Error-Message:
>   "Warning: Invalid argument supplied for foreach() in
>    E:...\class.db_list.inc on line 690"
>
> Problem 1:
> When a PHP-Error occurs in ListMode, the whole Output is displaced and you 
> can't see the docheaders anymore.
> Couldn't this be fixed within CSS (t3skin) ?
> I think it is necessary to get a readable/usable Output even if a 
> php-error (or e.g. a debug-message) appears.
>
> Problem 2:
> Couldn't / shouldn't class.db_list.inc be modified to produce a simple 
> error-message, so that you can see, what table created this error ?
> E.g.
> <snip>
>     if (!is_array($TCA[$table]['columns'])) {
>         echo "ERROR: Table '$table' - no columns available! <br />";
>     } else {
>         foreach($TCA[$table]['columns'] as $fN => $fieldValue) {
>     ...
> </snip>
> I think even this unstyled/untranslated message is better than a 
> php-error - right ?
>
> -

please no echo's!

The general problem is that any warnings and debug messages are printed out. 
This is an "old" problem of the docheaders because there are positioned 
absolute and not accessible any more if any Message is printed out on top.

Solution would be to buffer the output and put it in EXTRAHEADER

vg  Steffen 






More information about the TYPO3-dev mailing list