菜鸟求教,我是想删除一行的,为什么整个数据表的数据都被删了?
thinkphp吧
全部回复
仅看楼主
level 5
2014年12月04日 01点12分 1
level 1
你action跳转的都不对
2014年12月04日 05点12分 3
level 8
where(array('id'=>$id))
你的where 参数貌似等同 where(true)
2014年12月04日 16点12分 4
level 5
html多加个input用来传id,where用楼上的。
2014年12月05日 00点12分 5
楼主代码的特点,是不需要多搞个input传id的。一条记录走一个form,虽然很邪恶,但是在action中就可以传递这个id了. <form action="{:U('/Controller/method', array('id'=>$f['id']))}">
2014年12月07日 04点12分
1