Hide Row When Value is Equal to A Particular Value
-
Hello! I am having problems with hiding rows when a particular value is in the field.
I am importing a lot of product data in the form of a CSV. That is imported into Advanced Custom Fields. I want to display this information on the product page in a table form, but not all of the data fields apply to each and every product. For products where the information isn’t application, I have “N/A” in the field. I want to hide rows where N/A is the value. For this case in particular these are historical type knives. So here is the table I have:
`Knife Type [acf field=”knife_type”]
Model [acf field=”model”]
Blade Length [acf field=”blade_length”]
Second Blade [acf field=”second_blade”]
Steel [acf field=”steel”]
Handle Material [acf field=”handle_material”]
Tang [acf field=”tang”]
Bolster [acf field=”bolster”]
Hilt [acf field=”hilt”]
Butt [acf field=”butt”]
Liners / Spacers [acf field=”liners__spacers”]
Inlay [acf field=”inlay”]
Overall Length [acf field=”inlay”]Some of those values will turn up N/A, as it doesn’t apply to a particular knife.
I have tried the following shortcode:
[table id=1 filter=”N/A” filter_inverse=true /]But it didn’t work (yes table id is correct). My site isn’t published so I didn’t provide a link, maybe I could find a way around that somehow if it helps.
Does anyone have an idea on how I might achieve/approach this? I have tried with Attributes, but it doesn’t let me edit how the information looks, which is why I was trying Tablepress.
Thanks for the help!
- The topic ‘Hide Row When Value is Equal to A Particular Value’ is closed to new replies.