I found out that you can't really combine the ColdFusion form validation of
<cfinput> with other javascripts validation. I mean there is not built in
<textarea> CF validation. So I used an independent javascript validation for
the textarea along with the CF built in validation and the independent
javascript validating the <textarea> does not work. Probably has to do with
CF assigning another name to the form.
How do you validate a <textarea> with javascript along with using the built
in CF javascript validation with other form elements?
Sebastian
on 8/17/00 12:57 PM, Jamie Keane at [EMAIL PROTECTED] wrote:
> Your cfform needs a name. If you're just using HTML forms, you'll still
> need a name for your form to access the form's contents.
>
> --
> Jamie Keane
> Programmer
> SolutionMasters, Inc.
> 9111 Monroe Rd., Suite 100
> Charlotte, NC 28270
> www.solutionmasters.com
> 704.563.5559 x 228 Voice
> 704.849.9291 Fax
> -----Original Message-----
> From: sebastian palmigiani <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED] <[EMAIL PROTECTED]>
> Date: Thursday, August 17, 2000 1:50 PM
> Subject: javascript help
>
>
>> I'm trying to develop a javascript validation for a textarea. I'm getting
> an
>> error message which says "ProgramDescription.value" is not an object.
>>
>> ===========
>>
>> <script language="javascript1.2">
>> function validate(testform) {
>> if (testform.ProgramDescription.value == " ") {
>> window.alert("Please add a program description.");
>> return false;
>> }
>> return true;
>>
>> }
>> </script>
>>
>> <cfform action="AddNewProgram.cfm" method="post" ONSUBMIT="return
>> validate(this)">
>>
>> <textarea name="ProgramDescription" value="" cols="30" rows="10"
>> wrap="virtual"></textarea>
>>
>> <input type="submit" value="submit">
>> </cfform>
>>
>> Thanks,
>> Sebastian
>>
>>
>> ---------------------------------------------------------------------------
> ---
>> Archives: http://www.mail-archive.com/[email protected]/
>> To Unsubscribe visit
> http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
> send a message to [EMAIL PROTECTED] with 'unsubscribe' in
> the body.
>
> ------------------------------------------------------------------------------
> Archives: http://www.mail-archive.com/[email protected]/
> To Unsubscribe visit
> http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
> send a message to [EMAIL PROTECTED] with 'unsubscribe' in the
> body.
>
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.