form submit dumb question

message from J Fraze on 15 Jul 2004
I'm trying to create a "simple" form to perform a client side action that
gives a different price based on 3 variables selected by the user. All I
want to do is set up a situation where a specific number is posted to an
empty field within the page.

I hope this requires a simple java script. If this is a lot more complicated
than I'm thinking, I wonder if someone could point me to a tutorial or
sample script that might help me through this.
 
Mick White replied to J Fraze on 15 Jul 2004
Would the three variables be chosen from three different menus?
In other words, are the choices offered in the menu mutually exclusive?
For instance:
Car> Air Conditioning >None or Basic or Heavy Duty or Super
And would each choice have a specific dollar value (negative or positive)?
Are any or all of the three choices required?
Mick
 
Mick White replied to Mick White on 16 Jul 2004
You've lost me, I'm afraid.
It's easy enough to determine and display a price according to
selections made.
I think I would usher the user to the correct page first, and then
determine the price.
You say, no math, no addition, but there must be some logic involved in
reaching the correct price, and you're not telling me what it is.
Mick

J Fraze wrote:
 
J Fraze replied to Mick White on 15 Jul 2004
Yes. Closer!

If it helps, forget the numbers completely. Let's say the fields allowed you
to choose Color, Size, and Font. If the user selects Red, 200 pixels,
Helvetica from the form objects, then on Submit the page displays a specific
logo jpeg in its red, 200 pixel, Helvetica form. Other selections bring up
other versions according to the selections.

I believe the script would be the same. I'd just supply my number instead of
the graphic.

I imagine I could do it with one massive list supplying all the possible
configurations, but I think that would be pointless!

If it ends up being easier I suppose I could assign numerical values to the
options starting with a base price, but that seems more complex than
necessary. Maybe that's actually easier, though?
 
J Fraze replied to J Fraze on 15 Jul 2004
Thanks for the advice. I checked it out, and that seems more complex than
what I need. I don't need to calculate anything. I just have a list of set
prices that need to be supplied depending on the selections of the user. In
this case 15 price points. Which price point is displayed depends on a
combination of selections made in the three form objects.
 
Murray *TMM* replied to J Fraze on 15 Jul 2004
You can try the excellent CalcuateForm extension from Jaro -

http://www.yaromat.com

It works beautifully for doing things like this.
 
Murray *TMM* replied to Murray *TMM* on 15 Jul 2004
Oh, I see. It's not arithmentic calculation, it's a combinatorial one.

Mick White should be able to fix you right up! Yo, Mick!
 
J Fraze replied to J Fraze on 15 Jul 2004
For instance (to make the question clearer) the price would be different if
the user selects different options for the same object. I don't need to add
prices and calculate a total. Like the stock-photo houses use to calculate
cost of an image depending on size and print run. No math. Just different
price options for any item.
 
J Fraze replied to J Fraze on 15 Jul 2004
http://www.jonfraze.com/webpages/sample.html

The first object form chooses the page they start from onChange. The next
three are onSubmit objects, and the three together determine a set price
from about a dozen possibilities. The price would ideally be posted as plain
text at the end of the table. No addition, no math, no computations.

Seems it should be relatively easy, but I don't know where to find out how
to get or write the correct java script to process the form. I've been
trolling through the java reference in Dreamweaver for clues but so far
haven't figured anything out.
 
A.H.O. replied to J Fraze on 16 Jul 2004
Murray,
Would that link you provided show me how to put in fields where viewers could
enter numbers in say 2 fields, and have it calculate an answer?
In other words I would like to make a page where a user can inter arrow speed
and arrow weight into 2 seperate fields, and then have it calculate the kinetic
energy the arrow would hold based on those two changing variables. Does that
make sense? I know it's possible as Ive seen it. I just have NO clue how to
get it done.
 

Archived message: form submit dumb question (Macromedia Dreamweaver Web Design)