Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/232.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
php意外';meta#u值';(T_字符串)_Php - Fatal编程技术网

php意外';meta#u值';(T_字符串)

php意外';meta#u值';(T_字符串),php,Php,我得到这个错误,但无法找出原因 while($info = mysql_fetch_array( $data )) { echo itg_fetch_image('.$info['meta_value'].'); //the line giving error Print "<tr>"; Print "<th>ID:</th> <td>".$info['meta_id'] . "</td> "; Print "<th>

我得到这个错误,但无法找出原因

while($info = mysql_fetch_array( $data )) 
{ 
echo itg_fetch_image('.$info['meta_value'].'); //the line giving error
Print "<tr>"; 
Print "<th>ID:</th> <td>".$info['meta_id'] . "</td> "; 
Print "<th>VALUE:</th> <td>".$info['meta_value']. "</td> "; 
Print "<th>DONE:</th> <td>YES</td> "; 
} 
while($info=mysql\u fetch\u数组($data))
{ 
echo itg_fetch_image('.$info['meta_value']);//给出错误的行
打印“”;
打印“ID:”.$info['meta_ID']。”;
打印“值:”.$info['meta_VALUE']。”;
打印“完成:是”;
} 
如果我把这行注释掉,它在td值上显示的很好,我已经尝试了所有的方法。去掉点,去掉评论,然后加上“”。itg_fetch_图像为


代码是echo itg_fetch_image('url'),所有meta_值都返回一个url字符串。echo行上的引号导致了问题。 应该是这样的:

echo itg_fetch_image($info['meta_value']);

似乎
itg\u fetch\u image()
是一个函数

试试这个:

echo itg_fetch_image($info['meta_value']);
您可以只传递变量。不需要使用引号

你必须把它写成

echo itg_fetch_image($info['meta_value']);

echo itg_fetch_image($info['meta_value'])。引用是不必要的。这是有效的,正如你所说,它首先发布它作为一个答案,我会接受。谢谢,我不能,因为问题已经结束了。请随意选择第一个正确答案,因为他们也值得表扬。