From: Jason Woofenden Date: Mon, 25 Oct 2010 05:30:26 +0000 (-0400) Subject: metaform codegen: use tem_auto_unset() X-Git-Url: https://jasonwoof.com/gitweb/?p=wfpl.git;a=commitdiff_plain;h=4109b1932d56b8a509d746c25dfeaf6e8a5f6537 metaform codegen: use tem_auto_unset() --- diff --git a/metaform.php b/metaform.php index d134f92..fdd1ad3 100644 --- a/metaform.php +++ b/metaform.php @@ -83,12 +83,9 @@ function tem_set_globals(&$tem) { 'opt_pass'); foreach($bools as $bool) { if(format_bool($GLOBALS[$bool])) { - $tem->set($bool, 1); - } else { - $tem->set($bool . '_else', 1); + $tem->set($bool); } } - } function metaform() { diff --git a/metaform/template.html b/metaform/template.html index 58629d8..0e04ef9 100644 --- a/metaform/template.html +++ b/metaform/template.html @@ -74,7 +74,7 @@ -

Add a new ~singular~Edit ~singular~ "~~~always_field~ html~~"Submit a ~singular~

+

Add a new ~singular~Edit ~singular~ "~~~always_field~ html~~"Submit a ~singular~

@@ -115,7 +115,7 @@ - +
~caption~ 
~~~name~ ~listing_enc~~~~~~name~ ~listing_enc~~~ [delete this ~singular~]