Save Calculated Field result as global variable

[ad_1]

Hello @saralanda

Thank you so much for using our plugin.

Our plugin tries to extract numbers from fields’ values to use them in mathematical operations. However, the use of modifiers allows you to access their raw values. In your case, you should use the |r modifier.

If your calculated field is the fieldname123, you must refer to it in the second equation as fieldname123|r

The current plugin version supports other two modifiers |n and |v.

The |n modifiers tell the plugin you refer specifically to the field’s name instead of its value. The plugin replaces the fields’ names by their values in the equations before evaluating them. However, the |n modifiers tell the plugin you want to use the field’s name.

The |v modifier can be used in the equations with the names of the Radio Buttons, Checkbox, and Dropdown fields. The Radio Buttons, Checkbox, and Dropdown fields allow you to configure the value to submit between the texts of ticked choices or their values. The |v modifier tells the plugin you want to use the value to submit to the server (this would allow you access to the choices texts from the equations).

If you want to store the encodedTransport as a global variable, you only need to remove the var reserved word and assign the value directly.

Edit the line of code var encodedTransport = encodeURIComponent(transport);

As encodedTransport = encodeURIComponent(transport);

Best regards.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer