<span class="resolved" aria-label="Resolved" title="Topic is resolved."></span>Conditional and depndency

[ad_1]

Replies: 2

Hello,

thank you for creating this amazing plugin.

I am trying to display only one of the HTML fields based on the value in the calculated field.

Based on your answer to a similar question on this forum, I’ve tried this

(function(){
var result = fieldname9+fieldname10+fieldname11+fieldname12+fieldname13;
if( result <= 5 ) return ‘fieldname19’;
if( result <= 10 ) return ‘fieldname20’;
if( result <= 25 ) return ‘fieldname21’;
})()

but doesn’t work for me. I’ve tried to define dependencies but sometimes I would get 2 HTML fields to display.

What I am trying to achieve is :

if calculated field = 0 do nothing

if calculated field <= 5 show fieldname19 HTML content only

if calculated field <= 10 show fieldname20 HTML content only

if calculated field <= 25 show fieldname21 HTML content only

and a second question would be :

How can I set the button (fieldname17) to be active/clickable only if the Acceptance (GDPR) (fieldname16) is ON ?

 

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