Version 1.6.6 of Advanced Forms Pro was released just a few days ago and with it came some interesting little enhancements to the calculated field that allow you to do the following:
- Trigger calculated field rerenders whenever needed.
- Intercept the rendered preview markup and append it anywhere you need it on the page.
Why would you use these enhancements?
These enhancements make it possible to build more complex form previews that update while the user enters their data in the form. For an example of this in action, just take a look at our plugin review form.
The ability to control where the preview renders on the page offers even more possibilities as your preview will no longer be confined to the form’s markup – you can append the output to any HTML element on the page making it possible to have your form in one place and the rendered preview somewhere completely different!
How to trigger calculated field updates
Triggering calculated field update is really easy using any of the following formats:
How to control where the rendered preview appears
Intercepting the return values is also really easy and offers the same field targeting capabilities as the triggers:
To learn more about calculated fields an Advanced Forms Pro check out the related docs: