Quantcast
Channel: Adobe Community : Discussion List - ColdFusion
Viewing all articles
Browse latest Browse all 6243

Delete items unchecked from a form

$
0
0

I have a list from query that populate checkboxes (checked) in a form.

 

However, when a user deselects some of the items from, I want them to be deleted from the database for that user.

 

Here is the ex: this is how the form looks like:

 

                                         Category

Item                                  80      626

 

1. HS # 1 (87)                   chk    chk

2. HS #2  (59)                   chk    chk

 

 

This is the list of items already n their preferences (db ids)

 

80|87,  626|87,   80|59,   626|59

 

Now from a form, if they deselect one of the items (80|87), I want it to be deleted from the database.

 

Like these, DELETE FROM ITEMS_TBL WHERE ITEM_ID = 80, Category_ID = 87

 

How can we do it? Can we check ListContains or something else?


Viewing all articles
Browse latest Browse all 6243

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>