[Plugin: Flutter] Hiding Label When Key is Blank
-
Fresh Page is great! But am having the most obnoxious issue. There is probably a simple solution and I’m just missing it.
So when creating a post using Flutter, I often times only fill out about half of the fields I’ve created. But Flutter still creates custom fields for every field, simply leaving them blank. I’m using the following code to display the custom fields in my loop:
<?php $customField = get_post_custom_values("name"); if (isset($customField[0])) { echo "Name: ".$customField[0]."<br />"; } ?>
The problem is that since Flutter still creates the custom fields, but leaving them blank, I am still left with the label “Name:” on my post. How can I make the code conditional so if the custom field is blank, the label is not displayed?
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘[Plugin: Flutter] Hiding Label When Key is Blank’ is closed to new replies.