Home > Backend Development > PHP Tutorial > foreach后,什么也echo不出

foreach后,什么也echo不出

WBOY
Release: 2016-06-23 13:54:37
Original
1071 people have browsed it

<?php $_result2 = _query("SELECT * FROM dj");while (!!$_rows = _fetch_array_list($_result2)){ ?><tr><td><?php echo $_rows['bh'];?><input name="bh[]" type="hidden" value="<?php echo $_rows['bh'];?>"/></td></tr><?php$aa=$_POST['bh'];if (is_array($aa)){foreach ($aa as $bb){	echo $bb;}}}?>
Copy after login



为什么echo $bb,什么也没有?
是能显示出1,2,3,4……19,20,21的


回复讨论(解决方案)

已搞定!!!

$aa=$_POST['bh'];
post 提交后才会有值

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template