Merge branch 'master' of https://github.com/jgoodman/Freeside
[freeside.git] / httemplate / elements / tr-checkbox.html
index 2e6d1f1..5761263 100644 (file)
@@ -1,13 +1,18 @@
+<%doc>
+
+Example:
+
+  <& /elements/tr-checkbox.html,
+       'label' => 'Do or do not',
+       'field' => 'field_name',
+       'value' => 'Y',
+  &>
+
+</%doc>
 <% include('tr-td-label.html', @_ ) %>
 
   <TD <% $style %>>
-    <INPUT TYPE  = "checkbox"
-           NAME  = "<% $opt{field} %>"
-           ID    = "<% $opt{id} %>"
-           VALUE = "<% $opt{value} %>"
-           <% $opt{curr_value} eq $opt{value} ? ' CHECKED' : '' %>
-           <% $onchange %>
-    >
+    <% include('checkbox.html', @_) %>
   </TD>
 
 </TR>