What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.


  • Profile Image

    I looked in the forums, but can't find an answer..I need to divide a field's number by 1/2 and show in Paypal field, or another text field.* BUMP*

    Asked by fivetownhoopdreams on October 05, 2013 at 02:10 PM

    Example -

    User enters "$400" into field A

    in field B it shows "$200" and /or in Paypal area.

     

    Thanks!

    text field find thanks
  • Profile Image
    JotForm Support

    Answered by EltonCris on October 05, 2013 at 08:02 PM

    Hi,

    That's possible but that'd involve source code editing and applying custom script to achieved that function. How to get your Form Source Code

    If you require assistance on the script, let us know here with the form URL you'd like this function to be applied.

    Thanks!

  • Profile Image

    Answered by fivetownhoopdreams on October 06, 2013 at 01:17 PM

    @Jot Forum -

    Thanks, the url is:

    http://fivetownhoopdreams.net/regbasketballcamp.php

     

    We want the user to be able to enter the cost of the camp, and then it will give them 1/2 of the price in another field, or into Paypal.  I know most should be able to divide by 2, but most cant either.

    Thanks!

  • Profile Image
    JotForm Support

    Answered by jonathan on October 06, 2013 at 02:14 PM

    Hi,

    Thank you for updating us. We will get back to you with the necessary script computation code as soon as possible. We will notify you at once.

    Thanks. 

  • Profile Image
    JotForm Support

    Answered by jonathan on October 06, 2013 at 05:02 PM

    Hi,

    You can try a javascript code like this http://pastie.org/8382442

    This is a demo page where I used the form's source code + javascript calculator codes.

     

    You can do this on your end using this steps.

    1. Get your form's source code (guide: How-to-Download-a-Source-Code-of-your-Form)

    2. Embed form in your web page

    3. Copy the javascript calculate code from here http://pastie.org/8382442

    4. Paste the copied code into your web page. Make it is place on top before the [/head] tag

     

    5. Search in your web page embedded form's source code for the the form's field id# "input_58" . This is the camp cost field that will be computed.

    In my demo page, it can be found at line# 479

     

    6. Add the function code before the [/>] tag like this

    id="input_58" name="q58_campCost" style="width:60px" size="5" value="300" data-type="input-number" onblur="calculateCampCost();" />

    7. Save

    Test your form on your web page. Check if the calculate function is working.

    You can also view the source code of my demo page so that you can see how I did the setup. You can view the source using your browser.

    Hope this help. Inform us if further assistance is needed.

    Thanks.

  • Profile Image

    Answered by fivetownhoopdreams on October 07, 2013 at 10:36 PM

    Great, thank you very much!!

  • Profile Image
    JotForm Support

    Answered by ashwin_d on October 08, 2013 at 12:07 AM

    Hello fivetownhoopdreams,

    On behalf of my colleague you are welcome.

    Do get back to us if you have any further questions.

    Thank you!