Where can i find a IsAlphaNumeric UDF in ColdFusion

I am looking for a function in CFScript that can check whether or not a string is alphanumeric or not.  Could anyone help me?
Who is Participating?
_agx_Connect With a Mentor Commented:
You can use a regular expression like:

      <cfset foundAt = reFind("[^0-9a-zA-z]", string)>
       ... OR
       <cfset foundAt = reFind("[\W]", string)>  

<cfset string = "!absdfsdfsdfsdfsdf3213">
<cfset foundAt = reFind("[^0-9a-zA-z]", string)>
<cfif foundAt eq 0>
	Non-AlphaNumeric characters detected

Open in new window

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.