[thelist] CF: IsDefined() and Len() in one?

Frank framar at interlog.com
Tue May 8 00:48:44 CDT 2001


>  In a word - no. :)
>
>  If you're talking about the cumbersome task (in CF at
>  least) of working with form data and re-using forms, one
>  thing you might consider doing is CFPARAMing your form
>  field values together at the top of the action template
>  and checking for len (since the value will have already
>  be defined) in the processing portion of the template.
>
>  Of course, depending on what else you're doing with the
>  form values, this could just open up a whole new can of
>  worms.. ;)

I guess the question could have more precisely posed as "Does anyone 
have a more elegant solution?". I'm incessantly scheming how to 
create code that is increasingly terse AND readable. Better to double 
the comments and half the code, when possible. It's an interesting 
balance.

One example is where I re-use a form to find, edit, or insert. Mind 
you it takes me 6 pages to do instead of 3 8P, but I figure that at 
some point I should be able to do it in one. Just gettin' the chops 
down, baby.
-- 

Where there's a will, there's a way.

Frank Marion                      Loofah Communications
frank at loofahcom.com               http://www.loofahcom.com




More information about the thelist mailing list