foreach
statement.Though输入到
foreach
声明
是一个数组,它说阵列的foreach问题
Invalid argument supplied for foreach()
和我的代码看起来像这样
foreach($res_array as $res)
{
foreach($res as $re)
{
echo $re['shortUrl'];
}
}
和我的数组看起来像这样
Array ([errorCode] => 0 [errorMessage] => [results] => Array ([http://www.telegraph.co.uk/earth/earthpicturegalleries/5966251/The-weirdest-animals-on-Planet-Earth.html?image=5] => Array ([hash] => 2qNNV6 [shortUrl] => http://su.pr/2qNNV6)) [statusCode] => OK)
我得到那个错误为第二个foreach。请帮我解决这个问题。
更多信息请问什么语言/平台/等? – 2009-08-19 15:39:16
其在PHP ..... – Sakura 2009-08-19 16:06:18