From 0b816aa17bae22d15efb7bfe109ba86e0ec19ca5 Mon Sep 17 00:00:00 2001 From: real_nowhereman Date: Wed, 25 Nov 2009 10:12:42 +0000 Subject: [PATCH] {list_categories} new behavior : it now expects a parameter values=$array_of_values --- fp-includes/smarty/plugins/function.list_categories.php | 9 +++++---- fp-interface/sharedtpls/search.tpl | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/fp-includes/smarty/plugins/function.list_categories.php b/fp-includes/smarty/plugins/function.list_categories.php index eb49348..4fd54a1 100755 --- a/fp-includes/smarty/plugins/function.list_categories.php +++ b/fp-includes/smarty/plugins/function.list_categories.php @@ -71,6 +71,8 @@ function do_print_categories_list(&$lines, &$indentstack, &$result, $params) { $vt = $val[0]; $vid = trim($val[1]); + $catname = isset($params['name'])? $params['name'] : ''; + if ($indent > $indent_old) { array_push($indentstack, $indent); @@ -89,13 +91,12 @@ function do_print_categories_list(&$lines, &$indentstack, &$result, $params) { array_push($result, $ild); - $cat_entry = $smarty->get_template_vars('categories'); - if (!$cat_entry) $cat_entry = array(); + $cat_entry = isset($params['selected'])? $params['selected'] : array(); //list($catId) = each($categories); if (isset($params['type']) && ($params['type']=='form' || $params['type']=='check')) { - $string = '