there used to be a built in feature of fURL2a which allowed this with image
submit items - you just named them fuseaction_myfa and it did the rest.

For FB3 you're going to have to do this yourself, either by looping though
the form scope before you call the core, or maybe loooping the attributes
scope in  fbx_settings.cfm - not sure which would be considered "best
practise"...

Here's something i use which also allows cfid and cftoken to be passed
around in hidden form fields, though you'd need to call this before the
core. 
Currently it is looking for the image sumbits, hence the ".X" stuff, but it
could easily be changed to handle normal submit buttons - i'm just lazy and
use <input type=submit name="fuseaction_myfa.x"> if i need to.

HTH

Bert


/* #######################################################################
        SECTION THREE: GET FORM.CFID AND FORM.CFTOKEN INTO THE URL SCOPE
        AND CONVERT FORM.FUSEACTION_MyFA.X INTO form.fuseaction = "MyFA"
        to allow FUSEACTION name to be passed via an image submit button
####################################################################### */

for (i in form) {
  if (i IS "CFID" OR i IS "CFTOKEN") {
    StructInsert(url, i, form[i], true);
  } else if (Ucase(Left(i,11)) IS "FUSEACTION_" AND ListLast(i, '.') IS "X")
{
    StructInsert(form, "fuseaction", Mid(i,12,Len(i)-13), true);
  } 
}

ps i've got a sneaking suspision that i could shave nanoseconds from the
processing time by dumping the StructInsert and using 
   url[i] = form[i];
and 
   form.fuseaction = Mid(i,12,Len(i)-13);

pps and is that Ucase() necessary?

ppps has anyone ever looked at some old code and _not_ thought of ways to
"improve" it?

> -----Original Message-----
> From: Glenn, Patchworks Computers [mailto:[EMAIL PROTECTED]]
> Sent: 08 June 2002 03:05
> To: Fusebox
> Subject: Selective call to Fuses with one form
> 
> 
> I thought I saw someone demonstrate awhile back how to use 
> one form and
> have the fuse change based on the button form selection.
> 
> I thought it had something to do with the button name and value so you
> could have multiple buttons and the fuse would change 
> depending on what
> button was clicked.
> 
> Does anyone recall how to do this?
> 
> Thanks,
> 
> Glenn
> 
______________________________________________________________________
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to