probably want to do both CF and Javascript. do the validation in two steps,
first checking for minimum length, and then checking for at least one
non-alphabetic character. Here's CF and JS code:
------------------------------------------------------------
<cfif len(form.password) LT 8>
<!--- too short --->
</cfif>
<cfif REfind("[^a-zA-Z]", form.password) EQ 0>
<!--- only letters --->
</cfif>
------------------------------------------------------------
<script>
if (form.password.value.length < 8)
// to short
if (! /[^a-zA-Z]/.test(form.password.value))
// only letters
</script>
------------------------------------------------------------
---
Barney Boisvert, Senior Development Engineer
AudienceCentral
[EMAIL PROTECTED]
voice : 360.756.8080 x12
fax : 360.647.5351
www.audiencecentral.com
> -----Original Message-----
> From: Jillian Carroll [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, July 08, 2003 1:37 PM
> To: CF-Talk
> Subject: Password Validating
>
>
> I need to validate a password field, to ensure that it contains at least 8
> characters and at least 1 non-alphabet character.
>
> Does anybody have something handy that will help me with this?
> Should I use
> CF/RegEx or Javascript?
>
> Thanks!
>
> --
> Jillian
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription:
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Get the mailserver that powers this list at
http://www.coolfusion.com
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4