diff options
author | Bharat Mediratta <bharat@menalto.com> | 2008-11-27 06:34:20 +0000 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2008-11-27 06:34:20 +0000 |
commit | 850c3b90a3156cfa2e7030a3d343a1e479c0b4de (patch) | |
tree | 05e10f7e6627b46d82668e8b6500e378d800bec5 | |
parent | 3992dad4861c3a1296be7e0e7d4c7a46d621c1cc (diff) |
Don't wrap hidden elements in list items
-rw-r--r-- | themes/default/views/form.html.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/themes/default/views/form.html.php b/themes/default/views/form.html.php index 1933fb19..1873c53e 100644 --- a/themes/default/views/form.html.php +++ b/themes/default/views/form.html.php @@ -26,8 +26,10 @@ function DrawForm($inputs, $level=1) { } else { if ($input->error_messages()) { print "$prefix<li class=\"gError\">\n"; - } else { + } else if ($input->type) { print "$prefix<li>\n"; + } else { + // no type means its a "hidden" so don't wrap it in <li> } if ($input->label()) { print "$prefix {$input->label()}\n"; @@ -43,7 +45,9 @@ function DrawForm($inputs, $level=1) { print "$prefix </p>\n"; } } - print "$prefix</li>\n"; + if ($input->type) { + print "$prefix</li>\n"; + } } } } |