Concatenate Selects into PayPal data

home page

All this simple JavaScript (JS) plugin does is to accept the value fields from selects and concatenate them into various PayPal fields depending on the name suffix. These value fields may have different descriptions, price modifying information, item numbers or shipping costs in them.

We start with the output of the PayPal button factory and make a few changes. Then the JS processes the FORM and adjusts the fields. <view source> on this page to see what was done.

There are single-token, and three-token flags that may be used in the value field of the options.

Here is an example of what you may put into the value of an option field of a select...

  <option; value="Item #A1234 s1=10 s2=8.50 @25.00">...</option>

And here is how you direct the value of that option to the first option name field...

  <select name="color_1a" ...

Setting shipping is a little tricky, in that if you use it in any value field of a select, then you must use it in every value field, even if it is set to zero. Also, don't forget to include the hidden shipping and shipping2 fields in your FORM so they can be stuffed.

[picture] Blah, blah.

Color -     Fabric -     Size -

Input Quantity >   Total item cost >  

Image: XHTML 1.1 certified! Image: CSS2 certified! Image: Multi-user accessibility!

Contact me concerning this article at Mention "simple script" in your note.

Individual help starting at $25.00 for simple JS solutions.