Skip to main content
Apr 22, 2006 6:36 PM UTC
Question

Calculations with JavaScript

I am really new to this. I have used the tutorial with Dreamweaver to create a table based page. It is a registration form that has fields in the table that will need to be calculated. (# of registrations time $425.00 I have the JavaScript that will do that. Do I embed that in the fields by using an OnChange behavior? I can't find anything in the Help text telling me how to do this.
This topic is closed to new replies. Start a new post to keep the conversation going.

2 replies

Participating Frequently
Apr 23, 2006 1:50 PM UTC
If you written the Javascript already, you could create a Javascript function in your web page with that code. It's easiest to do this in Code View. Then, you can use the Call Javascript Behavior to run the function on the OnChange event for the field.
Translate
Inspiring
Apr 23, 2006 12:54 AM UTC
Its not a good idea to do money calculations on the client because it can be
scammed so easily. Pass the form data to the server and calculate there.

<%= Clinton Gallagher

"Flier46" <webforumsuser@macromedia.com> wrote in message
news:e2dt46$hsr$1@forums.macromedia.com...
>I am really new to this. I have used the tutorial with Dreamweaver to
>create a
> table based page. It is a registration form that has fields in the table
> that
> will need to be calculated. (# of registrations time $425.00 I have the
> JavaScript that will do that. Do I embed that in the fields by using an
> OnChange behavior? I can't find anything in the Help text telling me how
> to do
> this.
>


Translate