• Resolved minku56

    (@minku56)


    Hello. Thank you for the wonderful plugin. I have a question regarding a new calculation after the fields are reset.

    I enter the numbers in the fields that I want to calculate, press the calculate button and the total sum fields are showing. Is perfect.

    But when I reset the fields for a new calculation, the total sum fields are still showing and go along with calculation numbers.

    Is a way when I press the reset button the total sum fields to be hidden and showing again when I press the calculate button?

    It is somebody that can help me? Please. I can not find the answer and new in this kind of technology
    Thank you so much.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author codepeople

    (@codepeople)

    Hello @minku56

    Please, indicate the URL to the form to check the behavior you are describing in action.

    Best regards.

    Thread Starter minku56

    (@minku56)

    @codepeople , thank you for the fast response and implication. The URL is https://irinasasaki.com/diagonal-gift-wrapping/
    Best regards.

    Plugin Author codepeople

    (@codepeople)

    Hello @minku56

    You have assigned to the calculated fields the class name hide and then you have entered the following piece of code as the onclick event of the calculate button: jQuery('.hide').removeClass('hide');

    Edit your form as follows:

    1. Assign to the calculated fields two class names, the hide class name to hide them, and a custom class name to identify them, for example, my-field

    Note, to assign multiple class names to the same field, you should separate them by blank characters my-field hide

    2. Edit the onclick event in the calculate button as follows:

    
    jQuery('.my-field').removeClass('hide');
    

    3. Edit the onclick event in the reset button as follows:

    
    jQuery('.my-field').addClass('hide');
    

    Best regards.

    Thread Starter minku56

    (@minku56)

    @codepeople , thank you. I was trying like you send me and but unfortunately didnt work. I dont know what is happening, I tried before “my field” to put cff. ex: jQuery(‘.cff-my-field’) for both, reset and calculate button and is working.

    Thank you a lot.
    I wish you all the best.

    Plugin Author codepeople

    (@codepeople)

    Hello @minku56

    I see you did it with the .cff-calculated-field class and your form is working fine now.

    Best regards.

    Thread Starter minku56

    (@minku56)

    Yes, indeed. Thank you a lot @codepeople
    Best regards.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘A new calculation after reset the fields- » Plugin: Calculated Fields Form’ is closed to new replies.