[Javascript] Javascript and FF

Del Wegener del at delweg.com
Tue Sep 1 20:06:53 CDT 2009




> 
> Hello Del, 
> 
> 
>> In the past I assumed that the statement in line 189
>> function process_form(calculator)
>> did declare/define calculator.
> 
> 
> No, in fact it never did!
> 
> That's an internal local function argument/variable.
> 
> 
> 
>> I found the same error and am confused.
>> calculator is the name of the form.
> 
> 
> So it is a a name/id of a html element you are referring there!
> 
> Therefore, you were accessing that element directly by id/name.
> 
> 
> 
>> If that is no longer valid, what is? Where do I find such information?
> 
> 
> Lots of declarations instructions and values throughout the script 
> 
> are depending on that element. So, missing that element will cause
> 
> a general failure.
> 
> 
> 
> Therefore declaring: 
> 
> var calculator = document.getElementById('calculator');
> 
> (anywhere in your script)
> 
> May just bring it all back on gear. Cause there's no other 'true' error
> 
> there. 
Try:
Understood and appreciated.
Del




More information about the Javascript mailing list