mahpog
asked on
onBlur coldfusion validate
I have a text field that is entered (18 characters max). and I want to make sure this value does not
already exist on a table. Instead of validating after a submit, I would like to validate after entry is made,...
so onBlur.
I am trying to figure out how to write the function to make cfquery. If exists, error that need to re-enter new
value. I have done 'static' data checks but not a cfquery.
I am on CF 9
already exist on a table. Instead of validating after a submit, I would like to validate after entry is made,...
so onBlur.
I am trying to figure out how to write the function to make cfquery. If exists, error that need to re-enter new
value. I have done 'static' data checks but not a cfquery.
I am on CF 9
ASKER
I am attaching what happened. Anyone else with suggestions. i went to Adobe CF 9 Reference with 'same' (not quite) example. I need more help.
thx.
example.pdf
thx.
example.pdf
ASKER
Okay, I had a typo. and it is responding with "no record", or dump. But if the record exists, I want the user to re-enter a another number. If the record does not exist, then allow the entry and go to next field.
1. Usage of cfdebug
Add to your page which is holds cfdiv tag
e.g. : http://localhost/mypage.cfm?cfdebug
When ever any AJAX requests are posted, the debug window is updated.
2. You many not have to pass session variable. It is available across all requests/cfm pages.
Add to your page which is holds cfdiv tag
e.g. : http://localhost/mypage.cfm?cfdebug
When ever any AJAX requests are posted, the debug window is updated.
2. You many not have to pass session variable. It is available across all requests/cfm pages.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I did learn how to make my syntax work properly.
e.g.
<cfform name="form1">
YOUR INPUT FIELD:<cfinput name="stext1" type="text" >
</cfform>
<!--- CFDIV --->
<cfdiv bindonload="false" bind="url:CheckInput.cfm?i
style="background-color:##
For testing purpose use the following cfm file.
<!-- CheckInput.CFM --->
<cfdump var="#url#">