JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
added tem_auto_nonempty()
[wfpl.git] / template.php
index 9a512a6..396819d 100644 (file)
@@ -325,6 +325,14 @@ function tem_auto_show(&$value) {
        return $value;
 }
 
+# 'nonempty' sections will not be shown if the corresponding data
+# value is the empty string
+
+function tem_auto_nonempty(&$value) {
+       if($value === '') $value = null;
+       return $value;
+}
+
 # 'evenodd' sections are given an 'evenodd' attribute whose value
 # alternates between 'even' and 'odd'.