Another suggestion (or is it the same???) is to create the object with an
"input type=hidden" statement and a default value. Then when your page is read,
the object exists for the OnSubmit function.
Carol L. Bluestein
Senior Programmer
NYS Office of Real Property
518-486-6335
[EMAIL PROTECTED]
____________________Reply Separator____________________
Subject: Re: Javascript: Tearing my hair out
Author: [EMAIL PROTECTED]
Date: 3/8/01 9:12 AM
Put the script after you create the element. I had the same problem with a
clock on our web page.
Richard Ramos
Network Administrator
Softitler Net, Inc.
www.softitler.com
[EMAIL PROTECTED]
----- Original Message -----
From: "Windle, Kevan" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, March 08, 2001 9:03 AM
Subject: Javascript: Tearing my hair out
> I'm using IE5. Trying to do something really simple in javascript. The
> problem I'm having is this. I can reference a form element with inline
code.
> So passing this variable to a function like this works:
>
> <input
>
ondblclick="resetwhereboxes(this.value,3,document.forms.wheres.wherefield1.n
> ame)" type="text" size="10" name="wherefield1">
>
> then in the function:
>
> <SCRIPT type="text/javascript" language="JavaScript1.2"><!--
> function resetwhereboxes(fname){
> 1 document.write(fname);
> 2 document.write(document.forms.wheres.wherefield1.name);
> 3 document.write(document.forms[0].wherefield1.name);
>
>
> }-->
> </script>
> line 1 works. But line 2 and 3, give the error messages claiming there is
no
> such object.
>
> Anyone seen anything like this?
>
>
>
****************************************************************************
******
>
> The opinions expressed in this E-mail are those of the individual and
> not necessarily the company. This E-mail and any files transmitted
> with it are confidential and solely for the use of the intended recipients
>
>
****************************************************************************
******
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
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