- jolizzyAsked on March 06, 2012 at 01:19 PM
This will be used to calculate total pledge for a swimming event. E.G. Pledge amount X # of lengths swum = Total Pledge.
We will bill directly from Paypal after the event, so don't need payment options.
- gori-mathewAnswered on March 06, 2012 at 02:13 PM
Your question can be nswered using the following link of previous asked question of calculation three fields http://www.jotform.com/answers/67402-calculating-based-on-three-fields
Kindly have a look at the feaute and hope it will assist yiu.
- jolizzyAnswered on March 06, 2012 at 02:31 PM
Thank you--the payment tool requires a price to be defined, and the user needs to be able to set his own dollar amount.
- fxrAnswered on March 06, 2012 at 05:15 PM
There is no way at this time to allow form users to fill in their own value into a field and have calculations carried out based on it.
You may be able to approximate this functionality to a certain extent by having pre-defined values from which the form user can select e.g 1, 2, 3, 4, 5, 10 , 15 USD.. etc then building up the total from that.
- JotForm SupportabajanAnswered on March 07, 2012 at 12:53 PM
Is the form on this page the sort of thing you wanted? Submit it and have a look at the the auto-response. The submission records (of which you would not be privy to because it's not your form) do not contain the "$" symbol, as I figured it might interfere with calculations in some instances. However, a few adjustments can be made to the script to have it included there as well as in the email alerts.
- jolizzyAnswered on March 08, 2012 at 12:51 PM
I have to say, so far I am very impressed with your service. If we can get this to work, you people are going to make me look really good! :)
- jolizzyAnswered on March 08, 2012 at 12:58 PM
I used validation to enable numeric only in the pledge amount text box. If you can walk me through the Java, I would be grateful.
- fxrAnswered on March 08, 2012 at 03:08 PM
We will leave this one in abajans' more than capable hands, I am sure he will get back to you when he comes back on duty.
- JotForm SupportabajanAnswered on March 09, 2012 at 02:17 AM
- JotForm SupportabajanAnswered on March 10, 2012 at 03:53 AM
I haven't overslept or forgotten you! I got the solution to work in your form but I'm just trying to tidy up a few things in the code. I'll post the instructions here later today (Barbados time).
- jolizzyAnswered on March 10, 2012 at 04:09 PM
Abajan, Thank you! I appreciate your attention to this!
- gori-mathewAnswered on March 10, 2012 at 04:24 PM
Welcome and thanks for your appreciation and complements to our team especially Abajan, we feel great to hear that your were assisted.
- JotForm SupportabajanAnswered on March 12, 2012 at 04:24 PM
Hi again jolizzy
Do some submissions on this form and let me know if it's okay. If it is, I'll guide you as to what steps should be taken to implement the solution on your end.
We look forward to hearing from you.
- jolizzyAnswered on March 14, 2012 at 02:03 PM
Wayne, That looks great! The submissions seemed to work on my end... but of course, since they dumped the results into the report for your cloned form, I can't see them. I have about 2 weeks from today before this form has to go live. I'm looking forward to implementing your solution!
Once that's done, I'm sure I will think of a hundred more ways I can make this form easier to use! :) (Read--100 more ways I can think of to make the code more complex!)
- jolizzyAnswered on March 14, 2012 at 03:32 PM
Ah, here's another question already: once the amount is calculated in that field, can it automatically be plugged into a paypal payment field? The paypal field would only be visible if the user selected "now" in the "When processed" field.
If "After event" is selected, the user would receive an email with a payment request after the event is completed.
- pinoytechAnswered on March 14, 2012 at 04:17 PM
Yes, it posible to make condition that if the user choose "NOW" the paypal field would be visible.
I clone your form and create the condition that you want. Please take a look on this link
- jolizzyAnswered on March 14, 2012 at 05:15 PM
Oh, I see. If "NOW" is selected, then the paypal payment field shows; if "After event" is selected then the calc field that Wayne is working on shows. Cool!
- jolizzyAnswered on March 14, 2012 at 05:19 PM
How did you add the "Payment method" info and payment logos under the pledge amount box?
- pinoytechAnswered on March 14, 2012 at 06:07 PM
Kindly check your form now, I already added the Payment tools into your form and make condition that if the user choose "NOW" the paypal field would be visible.
If need further assistance, contact us anytime.
- jolizzyAnswered on March 14, 2012 at 07:22 PM
When the "credit card" radio button is checked, a whole name/address section of the form shows up for Paypal. Does the info there also get collected into my data file?
Also, I looked at the properties of that field, and there is a space for API Username and Password. Will this work for a regular Paypal account, or is it only for use with Payments Pro? I don't have any control over whether the organization subscribes to that service.
- JotForm SupportmlizAnswered on March 14, 2012 at 11:05 PM
We do not store the credit card information we only pass it securely to PayPal Website Payment Pro API for processing. You can find the payer information in your Paypal account. The API details is only available in Paypal Pro if you use a regular Paypal account you can use regular Paypal payment field which uses website payment standard integration.
- jolizzyAnswered on March 15, 2012 at 06:58 PM
Hi Wayne, I'm still looking forward to seeing your solution! :)
- JotForm SupportabajanAnswered on March 15, 2012 at 10:06 PM
I was just waiting until you had decided on the final format and functionality for the form. For example, the last time I checked, a "PayPal Pro" field was shown when "Now (fixed amount only)" was chosen in the "When would you like your pledge processed" field. Now I'm seeing something different.
I just want to have a clear picture of how all of the conditions in the form are to work before providing a solution. For instance, is something to happen on the form when the user chooses different payment methods or is that just information that will appear in the notification?
Incidentally, after just cloning the latest version of the form I noticed a duplicated condition:
(Click images to zoom)
Also, although it won't affect the functionality of the form, the following rules could have been combined in one condition by using the Add New Rule button (subsequent screenshot)
(Correction: The third rule alluded to in the screenshot above is actually a duplicate of the first rule and should therefore be deleted and not included in the condition below)
- jolizzy1Answered on March 19, 2012 at 02:40 PM
Hi Wayne, I accidentally went over my SSL limit while testing my form, so I cloned it to a new account. I have tried to clean up my rules as per your instructions above--hope I got everything! I will have to clone the forms one more time, to the pool's account. Would it be better to wait until I have done that before implementing your solution?
Hope it's a lovely day in Barbados... we have snow! Finally!
- JotForm SupportabajanAnswered on March 19, 2012 at 11:22 PM
If a drop down has been set to "Required", it should be blank when the page loads. Otherwise, users would be able to submit the form without any selection being made in that field. Therefore, "Please select" should be removed from the When would you like your pledge processed? field. The same applies to the If swimmer is unable to swim, field. The Pledge type field should be set in a similar fashion: "Required" and blank by default. Alternatively, each of those drop downs can be set to load with a default choice and the "Required" setting removed. So, in a nutshell, if a drop down is set to "Required", it should load with nothing selected and conversely, if a drop down is set to display a selection when the page loads, the "Required" setting should be removed.
Regarding the "Payment method" field, since the PayPal page has no option to pay by check, what happens if a user elects to pay by that method? (Regardless of what choices are made on the form, the PayPal payment page is always displayed after submission.)
After giving this much thought, I'm starting to wonder if it wouldn't be better to remove the current Total pledge field and rename the Donation field "Total pledge" (The "Donation" sub-label can be hidden with injected CSS). However, I'm not sure how feasible it would be to set that field to be editable under some circumstances and readonly under other conditions. So that bit of functionality may have to be omitted. Also, that field should be set to "Required" since you wouldn't want the form to be submitted without a pledge!
The Conditions Wizard
There's something regarding "Show/Hide" conditions about which you may not be aware: When a field is set to be shown under certain conditions, once those conditions are not met, it will be hidden. So, it's not necessary to specify any rules to hide the said field:
(The "HIDE Donation field" rule is unnecessary)
Lastly, the following rule is unnecessary because it already exists in the last condition:
If the condition below is clicked while in the Conditions Wizard, you'll see that it already contains the above rule. So, the above rule is unnecesary.
That's all for now. As to the weather, it was quite nice here today. Glad you got some snow!
- jolizzy1Answered on March 20, 2012 at 12:10 AM
Whew! So much information! Those conditionals get confusing. Ok, I have removed the duplicate conditions and removed the default answers in required fields.
Regarding the "Payment Method" field, if "When would you like your pledge to be processed" = "NOW", the payment method field is hidden and the paypal field is shown, so that they can complete their donation NOW.
If "When would..." = "After event", then the "Total Pledge" field will show, and based on the payment type field we will either email a request for payment of the amount calculated in the "Total Pledge" field (if the selected type is check), or we will send an invoice directly from paypal (if credit or paypal is selected as the payment type).
Does that make sense?
- JotForm SupportabajanAnswered on March 20, 2012 at 06:59 AM
RE: Paragraph 1
Pledge Type should be set to "Required" so that the script would know if to factor the number of lengths swum into the total pledge. If it becomes hidden due to a user selecting "Now (fixed amount only)", it will no longer be a required field.
RE: Paragraph 2
As to the Payment method field being hidden when "Now (fixed amount only)" is chosen, that was understood but if that option is selected and the user forgets to enter a donation amount before submitting the form, we don't want the following to happen on the PayPal page:
Setting the field currently labeled Donation to "Required" would prevent the user from submitting the form in the first place.
RE: Paragraph 3
Knowing that upon submission the PayPal page would load (regardless of what choices were selected on the form), I was wondering what a user who had chosen to pay by check would do when they got to the PayPal page:
Lastly, I had suggested that the Total Pledge isn't really necessary and that the Donation field could be renamed "Total Pledge".
- jolizzy1Answered on March 20, 2012 at 05:25 PM
RE: 1 & 2, I corrected them as you sugggested.
RE: 3, The paypal field is only available if "Pay Now" is selected. When the form is submitted with "Pay Now", it redirects to the paypal page. BTW, the pool doesn't have paypal pro, so we won't be using the API, just the regular paypal field. I'm considering having the address field hide for "Pay Now" so that the user only has to enter the info in paypal.
If "Pay After Event" is selected, the paypal field hides, and the "Pledge amount" and "Lengths" fields will show, along with the "Total Pledge", which would be the calculated field. If "After event" is selected, then regardless of the pledge type ("Fixed Amount" or "Per Length Amount"), after submission the user will be directed to a thank you page. After the event we will send emails (if check is selected) or paypal invoices (if paypal or credit is selected), according to the payment type selected.
So, the only time the paypal field is used is if the user opts to "Pay Now". That is why the paypal field is set to hide if the user selects to pay "After event"--so that it doesn't send them to paypal when they don't need it.
You can try the form as it is now and see how the paypal field works--mine works as described above. It will just open the paypal page, but it won't create a record in paypal until you submit a payment... just don't pay me, 'cause I won't pay you back! :-P
- JotForm SupportabajanAnswered on March 20, 2012 at 07:41 PM
Wherever did I get the idea that the PayPal page would "load after submission regardless of what choices were made on the form" from? The conditions you set up clearly showed that that would not happen and sure enough, after I just cloned the form and ran a test submission with "After event" selected in the When would you like your pledge processed? field, the following message was shown (as it should)
I'm sure your form is working as it should. I think I must have been trying to overanalyze it or something! Perhaps I need to step away from the form and come back to it in a couple days time :)
- jolizzy1Answered on March 20, 2012 at 09:31 PM
Take a brain break! See you in a couple of days. :)
- jolizzy1Answered on March 26, 2012 at 12:11 PM
I had a busy several days, but I'm back! This was suppposed to go live on Wednesday, but it looks like we have another couple of days, because I haven't gotten the confirmation I needed on another part of the event.
So, what needs to happen here?
Thanks in advance.
- jolizzy1Answered on March 26, 2012 at 01:17 PM
Ok, a couple of questions...
Before you give me the calc solution, do you want me to clone these forms into the pool's account?
The autorespond generates a link for swimmers to send to their potential donors, including the lengths they expect to swim. HOWEVER, will having the length info automatically plug into the donate form mess up the way the calc field works? I can take that out if you need me to.
- JotForm SupportabajanAnswered on March 26, 2012 at 06:22 PM
Before cloning the forms into the pool's account, let me run some tests to see how everything would work. To be honest, I don't know if prepopulated lengths will factor into calculations. It may well be that the script that performs the calculation may only work if information is input manually. It's not a question of if prepopulation will mess up anything but rather if values entered in such a manner will factor into the calculations. But my tests tonight will prove whether they would or not.
I'll get back to you in the morning.
- JotForm SupportabajanAnswered on March 27, 2012 at 06:19 AM
Just a quick update:
A test I ran showed that prepopulated lengths will be factored into calculations just like those which are manually inserted. This was my main concern.
I'll keep you posted.
- jolizzy1Answered on April 04, 2012 at 08:11 PM
The week has flown by... and now the form is supposed to go live tomorrow! YIKES! Any news about that calculation? We can lose the prepopulated length field if it mucks things up.
I think the issue is not so much whether prepopulated fields factor into calculations, but whether they mess with the calculation if someone selects fixed amount instead. In other words, if the lengths field is hidden when someone selects "fixed" pledge type, will the amount they enter in "Pledge amount" still be multiplied by the (hidden) prepopulated value in "lengths"?
- jolizzy1Answered on April 04, 2012 at 08:30 PM
BTW, the swimmer registration form is already live--I forgot to clone it to the swim team's account before I sent it out. For simplicity's sake, I'll use both forms in my account--note to self: remember to use the swim team's account next time!
- JotForm SupportabajanAnswered on April 04, 2012 at 09:32 PM
Yes, time appears to have run away from both of us! Anyway, go to http://www.jotform.co/form/20863308219857, complete and submit the form, test the links in the autoresponder, complete the pledge form as many times as you deem necessary to be assured that every thing is working properly. (I've set the notifications to go to your jolizzy address instead of the foresthillpool one. If you prefer that they be sent to the second one instead, let me know.)
After you have completed the tests, I'll roll back your submission count to its current number.
- JotForm SupportabajanAnswered on April 04, 2012 at 09:38 PM
Actually, I just realized that those submissions will be recorded in my account, not yours! So, there will be no need for me to rollback anything.
- jolizzy1Answered on April 04, 2012 at 09:40 PM
Ohh, I like your background! :)
And, excellent on the add a new swimmer link in the thank you page! I didn't know you could do that--much more elegant than my solution!
Please continue sending responses to j0lizzy--I don't have access to the Foresthillpool address.
- jolizzy1Answered on April 04, 2012 at 09:46 PM
Ok, the registration page looks good. Now for the calc field in the Pledge form.
Unfortunately, I am on my way to a pool board meeting right now, so will have to finish this up either tonight or tomorrow morning.
See you later!
- jolizzy1Answered on April 05, 2012 at 12:11 PM
I have an hour or so right now, so I hope you're available! What needs to happen with that calc field? I'm about to send the link out to the registrants I have so far, so if we can get that set up before they need to use it, I would be grateful.
- plongeonAnswered on July 16, 2012 at 02:51 PM
- JotForm SupportNeilVicenteAnswered on July 16, 2012 at 06:22 PM
Wayne's solution require modification of the form's source codes and embedding it to an external server. Obviously, JotForm does not allow custom scripts to be saved using the Free Text tool (for security reasons).
Hence, the only way to make this work is to have the modified codes embedded on an externally-hosted webpage.
- plongeonAnswered on July 18, 2012 at 12:24 PM
Thank you for the answer. That is what I expected... unfortunately.
Why don't you allow the insertion of <script> tags in Custom HTML fields? It would open so much possibilities.
- JotForm SupportabajanAnswered on July 18, 2012 at 02:36 PM
Unfortunately, it would also open so many vulnerabilities and we simply can't risk that.