Re: Alternative to using CONTAINS repeatedly?

2008-09-18 Thread Julie Davenport
To all who replied and offered advice, thank you very much. Sorry for the delay in responding. Good tips from all, thanks again. Julie ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get

Alternative to using CONTAINS repeatedly?

2008-09-12 Thread Julie Davenport
Hello all, I'm trying to screen out bad stuff sent to my scripts in the form fields and I know there has to be a better way to do it than this: cfif lcase(form.First_Name) CONTAINS 'http' OR lcase(form.First_Name) CONTAINS 'script' OR lcase(form.First_Name) CONTAINS 'img' OR

Re: Alternative to using CONTAINS repeatedly?

2008-09-12 Thread Claude Schneegans
lcase(form.First_Name) First of all, you could avoid calling the lcase function 6 times on the same expression: store lcase(form.First_Name) once for all in one variable, and use this variable in your tests. But this is just a general consideration. What you need here is some regExp, ie cfif

RE: Alternative to using CONTAINS repeatedly?

2008-09-12 Thread Adrian Lynch
cfelse Bo :O( /cfif Adrian -Original Message- From: Julie Davenport [mailto:[EMAIL PROTECTED] Sent: 12 September 2008 15:54 To: CF-Talk Subject: Alternative to using CONTAINS repeatedly? Hello all, I'm trying to screen out bad stuff sent to my scripts in the form fields and I

Re: Alternative to using CONTAINS repeatedly?

2008-09-12 Thread Mike Chabot
:54 To: CF-Talk Subject: Alternative to using CONTAINS repeatedly? Hello all, I'm trying to screen out bad stuff sent to my scripts in the form fields and I know there has to be a better way to do it than this: cfif lcase(form.First_Name) CONTAINS 'http' OR lcase(form.First_Name

Re: Alternative to using CONTAINS repeatedly?

2008-09-12 Thread Dana Kowalski
Couldn't you scale those down by setting a var up top with the script, img etc. Also set a var so you don't have to repeat the lcase(). Then use a few listFindNoCase()'s ? ~| Adobe® ColdFusion® 8 software 8 is the most