Wow.. thanks again!

Wasn't expecting that much of an answer.. but who's complainin'!  ;)

Will get on this right away.. thanks!

Lee Fuller
Chief Technical Officer
PrimeDNA Corporation / AAA Web Hosting Corporation
"We ARE the net."
http://www.aaawebhosting.com



> -----Original Message-----
> From: Dick Applebaum [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, July 04, 2001 10:07 AM
> To: CF-Talk
> Subject: RE: Stripping non-alpha characters...
> 
> 
> Lee
> 
> In order to cause a window to popup, you need to perform the test 
> with JavaScript on the client side.
> 
> For version 4+ browsers (which use JavaScript 1.2) the code would 
> look something like this:
> 
>    <script language="JavaScript1.2">
> 
>    function checkAlpha(alphaField) {
>      if( alphaField.value.match(/[^A-Za-z]/g) != null ) {
>        alert('The ' + alphaField.name +
>         ' may contain alphabetic chartacters only!');
>        return false;
>      }else{
>        alert('The ' + alphaField.name + ' passes!');
>        return true;
>      }
>    }
> 
>    </script>
> 
>    <form name="myForm" onSubmit="alert('The Form is being Submitted!')">
>      <input type="text"   name="Password" value="Enter Password" 
> size="20" >
>      <input type="submit" name="SubmitPW" value="Submit"
>        onClick="return checkAlpha(document.myForm.Password);">
>    </form>
> 
> 
> HTH
> 
> Dick
> 
> 
> At 8:31 AM -0700 7/4/01, Lee Fuller wrote:
> >Excellent!
> >
> >Now another question:
> >
> >- Do you have a variation of this that YOU would use to check for the
> >existence of (and potentially return) non-alpha characters in the same
> >string, before replacing them?  I.e., to pop-up a java window and say
> >"Sorry.. these characters (.#) are not allowed in the username."
> >
> >     Lee
> >
> >
> >>  -----Original Message-----
> >>  From: Dick Applebaum [mailto:[EMAIL PROTECTED]]
> >>  Sent: Tuesday, July 03, 2001 11:40 PM
> >>  To: CF-Talk
> >>  Subject: Re: Stripping non-alpha characters...
> >>
> >>
> >>  Try:
> >>
> >>     <cfset x = "a1B,2c.3D4">
> >  >    <cfset y = ReReplace(x, "[^A-Za-z]", "", "All")>
> >>     <cfoutput>#y#</cfoutput>
> >>
> >>  HTH
> >>  Dick
> >>
> >>  At 11:13 PM -0700 7/3/01, Lee Fuller wrote:
> >>  >Anyone have a quick, down and dirty method of stripping non-alpha
> >>  >characters, that they'd like to share?  Something that would 
> be good to
> >>  >check/strip potential login names for email (as an example).
> >>  >
> >>  >TTAIA!
> >>  >
> >>  >
> >>  >Lee Fuller
> >>  >Chief Technical Officer
> >>  >PrimeDNA Corporation / AAA Web Hosting Corporation
> >>  >"We ARE the net."
> >>
> >>
> >
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

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

Reply via email to