/views/plugins/function.hidden.php
PHP | 19 lines | 11 code | 8 blank | 0 comment | 1 complexity | 5ee64abf710483233f73533dea348511 MD5 | raw file
Possible License(s): LGPL-3.0
- <?php
- function smarty_function_hidden($params, $template) {
- if (empty($template->smarty->view->loaded['form'])) {
- trigger_error("{hidden} command requires Form helper.", E_USER_ERROR);
- }
-
- $name = 'foo';
-
- extract(compact('template') + $params);
-
- unset($params['name']);
-
- $form = $template->smarty->view->loaded['form'];
-
-
- return $form->hidden($name, $params);
- }