开发者

uploading large GIFS with Kusaba

This doesn't always happen. I could upload the same GIF sometimes and sometimes receive back this erro开发者_运维知识库r, it seems almost random.

Warning: Invalid argument supplied for foreach() in /webroot/i/n/*001/*.org/www/inc/classes/board-post.class.php on line 81
Warning: Cannot modify header information - headers already sent by (output started at /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php:81) in /webroot/i/n/*/*.org/www/board.php on line 343
Warning: Cannot modify header information - headers already sent by (output started at /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php:81) in /webroot/i/n/*/*.org/www/board.php on line 347
Warning: Cannot modify header information - headers already sent by (output started at /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php:81) in /webroot/i/n/*/*.org/www/board.php on line 350
Warning: Invalid argument supplied for foreach() in /webroot/i/n/*/*.org/www/inc/func/posts.php on line 249
Warning: Invalid argument supplied for foreach() in /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php on line 136
Warning: Invalid argument supplied for foreach() in /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php on line 163
Warning: Invalid argument supplied for foreach() in /webroot/i/n/*/*.org/www/inc/func/fetching.php on line 27
Warning: Invalid argument supplied for foreach() in /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php on line 343
Warning: Invalid argument supplied for foreach() in /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php on line 443
Warning: Invalid argument supplied for foreach() in /webroot/i/n/*/*.org/www/inc/func/fetching.php on line 27
Warning: Cannot modify header information - headers already sent by (output started at /webroot/i/n/*/*.org/www/inc/classes/board-post.class.php:81) in /webroot/i/n/*/*.org/www/inc/func/misc.php on line 76


Somewhere you're using a variable that's not an array in a foreach statement, like:

$foo = 123;
foreach ($foo as $bar)

This throws the Invalid argument supplied for foreach() warning. Check your variables better to make sure they're arrays when they're expected to be.

The fact that this warning was thrown and output blocks headers from being sent, which causes the other Cannot modify header information warning.


If you want to cycle through the $results array, you should write

foreach ($results as $key=>$value)

rather than

foreach ($results[0] as $key=>$value)

unless $results[0] itself is an array, in which case $results would be a matrix (array of arrays).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜