我很困惑为什么会发生这个错误,如果有人可以帮忙
foreach ( $filters as $_filter )
{
switch ($_filter[1])
{
case "/FlateDecode" :
if (function_exists("gzuncompress") )
{ echo 'testing1';
$xrefStreamData = 0 < strlen( $xrefStreamData ) ? gzuncompress( @$xrefStreamData ) : "";
}
else
{
$this->error( sprintf( "To handle %s filter, please compile php with zlib support.", $_filter[1] ) );
}
if ( $xrefStreamData === false )
{ echo 'testing2';
$this->error( "Error while decompressing stream." );
}
break;
case "/LZWDecode" :
echo 'testing3';
include_once( "filters/FilterLZW_FPDI.php" );
//does not go through
$decoder = new FilterLZW_FPDI( $this->fpdi );
$xrefStreamData = $decoder->decode( $xrefStreamData );
break;
case "/ASCII85Decode" :
echo 'testing4';
include_once( "filters/FilterASCII85_FPDI.php" );
$decoder = new FilterASCII85_FPDI( $this->fpdi );
$xrefStreamData = $decoder->decode( $xrefStreamData );
break;
case null :
break;
}
$this->error( "Unsupported Filter: %s", $_filter[1] );
}
我将回声设置为调试以查看它通过哪些循环,我得到的输出是 testing1 unsupported Filter %s
这是否意味着数组$_filter
为空?如果它为空,为什么它首先进入 foreach 循环?