![]() |
Changing quanity/price
Hi,
I am having some problems I am not the greatest with this type of things I am trying to do. I am looking for an answer and a easy way to learn to do this. First off I want my customer to be able to change the quantity then when they pick the quantity the price will change automatically. I know there is a paypal way to do this but I want it to be done on my site. I am selling site credits kind of like zynga cash on the facebook games. Kind of like <select name="howmany"> They will choose one of them options but there are three options to purchase and they are $5 $10 and $15 Now let's say if they choose 5 as the quantity and the $10 option then it updates to $50 and what ever the credit amount updates as well to 5 times the original. If you need more info just ask me. |
it seems that your best fit is using javascript listening to the SELECT onChange event. I don't know where you want the result to come up so I am going to put it in an input text for this example:
the html html Code:
javascript Code:
That is untested code, just came up with it. It just shows the gist of the behavior you wanted. |
I figured it out. Thanks Tony here is what I did
of course I used the same HTML selection option and just did this PHP Code:
|
| All times are GMT. The time now is 12:32 PM. |
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0