dynamic fields control a view

By: Alan Kindree | Asked: 12/14/2022
ForumsCategory: General questionsdynamic fields control a view
Alan KindreeAlan Kindree asked 2 years ago
I have a star form that works.  On that form below the stars I have up and down votes that result in a score above or below zero.  I want that dynamic field [9179] to turn a view field on or off.  [if 9179 greater_than ="0"]My View  [3333][/if 9179] My wild guess is [if [frm-field-value field_id=9179 post_id="[ID]"] greater_than="0"]My View [3333][if/ [frm-field-value field_id=9179 post_id="[ID]"] This isn't working.  Any ideas?  If you solve this, what is it worth to you? [email protected] Well I guess 9179 is not a dynamic score as it just adds the up and down votes together.
1 Answers
Best Answer
Bobby Clapp answered 2 years ago
It doesn't work that way. It sounds like you might need the more complex frm-condition shortcode. https://formidableforms.com/knowledgebase/compare-two-values-for-display/
Alan KindreeAlan Kindree replied 2 years ago

Thanks Bobby, I will look at that
Merry Christmas

Alan KindreeAlan Kindree replied 2 years ago

[frm-condition source=frm-field-value field_id=391 entry=[id] greater_than="0"]your content here[/frm-condition]

so would that be it for values greater than zero to dispaly?

Alan KindreeAlan Kindree replied 2 years ago

and 391 can be from a second form?

Bobby Clapp replied 2 years ago

In this case, the form from which the field comes form does not matter. If the value of field 391 in whatever form it exists, specific to an entry id (dynamic here as defined by [id], you can define the entry id number) where that value is greater than 0, it will display the information within (here, "your content here").

Alan KindreeAlan Kindree replied 2 years ago

This displays the value from the other form that I want to use [frm-stats id=9283 type=total 8372="[id]"] So I am guessing [frm-condition source=frm-field_id=9283 entry=[id] greater_than="0"]your content here[/frm-condition] will turn on the field if that value is greater than zero. Is this correctly formatted?

I tried [frm-condition source=frm-field-value field_id=9283 entry=[id] greater_than="0"]your content here[/frm-condition] without result

Alan KindreeAlan Kindree replied 2 years ago

maybe the type=total should also be used as thats what I want

Alan KindreeAlan Kindree replied 2 years ago

it is for a nonprofit described here piratedivebar.com/about

Alan KindreeAlan Kindree replied 2 years ago

[frm-condition source=frm-field_id=9283 entry=[id] type=total greater_than="0"]your content here[/frm-condition]

Alan KindreeAlan Kindree replied 2 years ago

That does not work either

Bobby Clapp replied 2 years ago

What happens if you remove entry=[id]?

Alan KindreeAlan Kindree replied 2 years ago

[frm-condition source=frm-field_id=9283 type=total greater_than="0"]your content here[/frm-condition]

I will check

Alan KindreeAlan Kindree replied 2 years ago

Nada

Alan KindreeAlan Kindree replied 2 years ago

<p>It is on this page BTW <a href="https://piratedivebar.com/competitors/&quot; rel="nofollow">https://piratedivebar.com/competitors/</a></p&gt;

Alan KindreeAlan Kindree replied 2 years ago

This is the very last thing I need to figure out before cleaning up my construction debris in the site. It is supposed to help the families of heroes produce youtube videos of their disabled loved ones. We just found a church that will host us.

Alan KindreeAlan Kindree replied 2 years ago

[frm-condition source=frm-field_id=9283 type=total 8372="[id]" greater_than="0"]your content here[/frm-condition] is was my next guess. NADA again

Alan KindreeAlan Kindree replied 2 years ago

[frm-condition source=frm-field_id=9283 type=total entry=[id] greater_than="0"]your content here[/frm-condition] also NADA

Bobby Clapp replied 2 years ago

The link you shared may help. What's the goal exactly? Are you trying to only show entries in the view that have ratings?

Alan KindreeAlan Kindree replied 2 years ago

[frm-stats id=9283 8372="[id]" type=total greater_than="1"]your content here[/frm-stats] that returned the correct value but the "your content here" did not appear

Alan KindreeAlan Kindree replied 2 years ago

looks like I got my message windows mixed up

Alan KindreeAlan Kindree replied 2 years ago

This displays the value from the other form that I want to use [frm-stats id=9283 type=total 8372="[id]"] So I am guessing [frm-condition source=frm-field_id=9283 entry=[id] greater_than="0"]your content here[/frm-condition] will turn on the field if that value is greater than zero. Is this correctly formatted?

Alan KindreeAlan Kindree replied 2 years ago

My goal is to have features turned on or off by the moderation score.

Alan KindreeAlan Kindree replied 2 years ago

People vote and features are turned on or off

Alan KindreeAlan Kindree replied 2 years ago

for individual posts

Bobby Clapp replied 2 years ago

Can you share some screenshots of the view code setup that displays the data you intend to filter through?

Alan KindreeAlan Kindree replied 2 years ago

[frm-stats id=9283 8372="[id]" type=total] [greater_than="1"]]your content here[/frm-stats] also produces the moderation score but not the text

Alan KindreeAlan Kindree replied 2 years ago

You mean of the content window in the view?

Bobby Clapp replied 2 years ago

yes

Bobby Clapp replied 2 years ago

Try this: https://postimages.org/

Alan KindreeAlan Kindree replied 2 years ago

This site keeps crashing when I send

Bobby Clapp replied 2 years ago

Frm stats isn't a conditional in the way that it will display data wrapped in closing tags like that. You have to use something like:

[frm-condition source=frm-stats id=25 type=count 25="red" less_than=10]content here[/frm-condition]

Maybe:

[frm-condition source=frm-stats id=9283 type=total 8372="[id]" greater_than=1]content here[/frm-condition]

Alan KindreeAlan Kindree replied 2 years ago

I like that I will try it

Alan KindreeAlan Kindree replied 2 years ago

hahaha so far so good! I will keep testing

Alan KindreeAlan Kindree replied 2 years ago

Second test worked too! Very impressive thanks Bobby. I am going to keep testing. That was the last puzzle piece.

Making the Best WordPress Plugin even better - Together

Take on bigger projects with confidence knowing you have access to an entire community of Formidable Experts and Professionals who have your back when the going gets tough. You got this!
Join the community
crossarrow-right