Re: Deleting Multiple Database Records based on Checkbox
This WebDNA talk-list message is from
1998
It keeps the original formatting.
numero = 18978
interpreted = N
texte = Can anybody tell me what's wrong with this. Like Kim earlier, I'm trying toupdate multiple records with a simple checkbox value. This all lookscorrect but doesn't work. I've viewed the formvariables and there allcorrect, it should trigger the replace context. But nothing happens.Checkbox coming off of the formReplace process.[formvariables][showif [name]=update][replacedb=../dbase/story.db&eqstoryID=[value]]blah=&oldStory=T[/replace][/showif][/formvariables]Even added the blah= incase there was something wrong there.This looks good to me, what am I missing. It flat doesn't work.try it.http://www.quake.org/adminRayAt 11:22 PM 7/21/98, you wrote:>At 10:51 Uhr 21.07.1998, Kimberly Wyrick wrote:>>I've searched the>>archives, and so far haven't found any past discussion on deleting multiple>>database records based on a checkbox...>>>>Database fields: username, todoitem, priority, deadline>>>Add a field with a unique ID to your database:>todoID, username, todoitem, priority, deadline>(you can use [cart] to generate the ID when you store a new record)>>In your form, name the checkboxes with some prefix and their ID's:>delete>>On your response page:> [formvariables]> [showif [name]^cb_]> [DELETE db=todo.db&eqIDdata=[getchars start=4][name][/getchars]]> [/showif]> [/formvariables]>How it works:>Checkboxes which are activated show up inside the [formvariables] loop,>others not.>With [showif] you ask if it is a checkbox you want to deal with (because of>its prefix cb_)>Inside the DELETE context the pure ID gets extracted and the record deleted.>>>Peter>>__________________________________________>Peter Ostry - po@ostry.com - www.ostry.com>Ostry & Partner - Ostry Internet Solutions>Auhofstrasse 29 A-1130 Vienna Austria>fon ++43-1-8777454 fax ++43-1-8777454-21> WebmasterMind Information Systemshttp://www.mindinfo.com
Associated Messages, from the most recent to the oldest:
Re: Deleting Multiple Database Records based on Checkbox (Raymond Hatch 1998)
Can anybody tell me what's wrong with this. Like Kim earlier, I'm trying toupdate multiple records with a simple checkbox value. This all lookscorrect but doesn't work. I've viewed the formvariables and there allcorrect, it should trigger the replace context. But nothing happens.Checkbox coming off of the formReplace process.[formvariables][showif [name]=update][replacedb=../dbase/story.db&eqstoryID=[value]]blah=&oldStory=T[/replace][/showif][/formvariables]Even added the blah= incase there was something wrong there.This looks good to me, what am I missing. It flat doesn't work.try it.http://www.quake.org/adminRayAt 11:22 PM 7/21/98, you wrote:>At 10:51 Uhr 21.07.1998, Kimberly Wyrick wrote:>>I've searched the>>archives, and so far haven't found any past discussion on deleting multiple>>database records based on a checkbox...>>>>Database fields: username, todoitem, priority, deadline>>>Add a field with a unique ID to your database:>todoID, username, todoitem, priority, deadline>(you can use [cart] to generate the ID when you store a new record)>>In your form, name the checkboxes with some prefix and their ID's:>delete>>On your response page:> [formvariables]> [showif [name]^cb_]> [DELETE db=todo.db&eqIDdata=[getchars start=4][name][/getchars]]> [/showif]> [/formvariables]>How it works:>Checkboxes which are activated show up inside the [formvariables] loop,>others not.>With [showif] you ask if it is a checkbox you want to deal with (because of>its prefix cb_)>Inside the DELETE context the pure ID gets extracted and the record deleted.>>>Peter>>__________________________________________>Peter Ostry - po@ostry.com - www.ostry.com>Ostry & Partner - Ostry Internet Solutions>Auhofstrasse 29 A-1130 Vienna Austria>fon ++43-1-8777454 fax ++43-1-8777454-21> WebmasterMind Information Systemshttp://www.mindinfo.com
Raymond Hatch
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...