diff options
Diffstat (limited to 'plugins/function.parse_service.php')
-rw-r--r-- | plugins/function.parse_service.php | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/plugins/function.parse_service.php b/plugins/function.parse_service.php deleted file mode 100644 index aa9983d..0000000 --- a/plugins/function.parse_service.php +++ /dev/null @@ -1,26 +0,0 @@ -<?php - -function smarty_function_parse_service($params, Smarty_Internal_Template $template) -{ - if (empty($params['var'])) { - trigger_error("assign: missing 'var' parameter"); - return; - } - - if (!in_array('value', array_keys($params))) { - trigger_error("assign: missing 'value' parameter"); - return; - } - - $name = $params['value']; - $port = null; - - if (is_array($params['value'])) { - $name = array_keys($params['value'])[0]; - $port = array_values($params['value'])[0]; - } - - $template->assign($params['var'], array('name' => $name, 'port' => $port)); -} - -?> |