Thread: checkbox update
View Single Post
Old April 18th, 2006, 10:53 AM
keyvanjan keyvanjan is offline
Friend of Wrox
Join Date: May 2005
Location: , , .
Posts: 149
Thanks: 0
Thanked 0 Times in 0 Posts
Default checkbox update

I have a form that has some checkboxes named "interests" like this:
<input type=checkbox name=interests value="sport">
<input type=checkbox name=interests value="Internet">
<input type=checkbox name=interests value="Books">

I add them to a field called "interests" in the database
and as you know they will be added with a comma separated(if user checks all thr boxes)like this sports,books,internet

Now I have a form that gets the values of all fields from the db
I get the values of all fields but how Can I update the interest field
if there was just one value I used this code:
<input type=checkbox name=interests value="<%=rs("interests")%>">
But now I have more than 1 checkbox
I need the code please!