condition=""
for i=1 to num
if request("kf_id"&i)<>"" then
condition=condition+" or userid="& sqlstr(request("kf_id"&i))
end if
next
condition=mid(condition,4) ’这段是消除头上多余的那个的那个or和空格
<!--这样就得到了condition 那记录了所有的kf_id里面的value 并也or 累加-->
我想可能你的目的也是将它门递交数据库做处理。所以下面
if condition<>"" and submit<>"选择" then
adddb = "update dorm set dorm_mark=dorm_mark-10 where "&condition
conn.execute(adddb)
end if
to minmin127(笨笨)
谢谢
但是未选中,就没有值吗?
我做的是这样一个页面
有许多checkbox
有选中的和未被选中的
我用
for i=1 to checkbox的个数
a(i)=request.form("is_nullable")
next
却总是报索引错误!
一查原因,发现如果checkbox未被选中的话,是没有值传过来的,不管你是否给value赋了什么值!
这个有办法解决吧!