aboutsummaryrefslogtreecommitdiffstats
path: root/include/smarty/libs/plugins/function.counter.php
diff options
context:
space:
mode:
authorrvelices <rv-github@modusoptimus.com>2013-06-20 03:38:47 +0000
committerrvelices <rv-github@modusoptimus.com>2013-06-20 03:38:47 +0000
commit6fc07742f8fca9d32db23243d374ea27e8ee4c1e (patch)
treebc7240c53a1c6bdff6c785153deb6306585c4062 /include/smarty/libs/plugins/function.counter.php
parent9843eb362dd7d1b9d762871777ef76fa84e8202a (diff)
smarty 3 - first pass for tests
git-svn-id: http://piwigo.org/svn/trunk@23384 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'include/smarty/libs/plugins/function.counter.php')
-rw-r--r--include/smarty/libs/plugins/function.counter.php18
1 files changed, 8 insertions, 10 deletions
diff --git a/include/smarty/libs/plugins/function.counter.php b/include/smarty/libs/plugins/function.counter.php
index 1f26db5fb..3906badf0 100644
--- a/include/smarty/libs/plugins/function.counter.php
+++ b/include/smarty/libs/plugins/function.counter.php
@@ -2,24 +2,24 @@
/**
* Smarty plugin
* @package Smarty
- * @subpackage plugins
+ * @subpackage PluginsFunction
*/
-
/**
* Smarty {counter} function plugin
*
* Type: function<br>
* Name: counter<br>
* Purpose: print out a counter value
+ *
* @author Monte Ohrt <monte at ohrt dot com>
- * @link http://smarty.php.net/manual/en/language.function.counter.php {counter}
+ * @link http://www.smarty.net/manual/en/language.function.counter.php {counter}
* (Smarty online manual)
- * @param array parameters
- * @param Smarty
+ * @param array $params parameters
+ * @param Smarty_Internal_Template $template template object
* @return string|null
*/
-function smarty_function_counter($params, &$smarty)
+function smarty_function_counter($params, $template)
{
static $counters = array();
@@ -43,7 +43,7 @@ function smarty_function_counter($params, &$smarty)
}
if (isset($counter['assign'])) {
- $smarty->assign($counter['assign'], $counter['count']);
+ $template->assign($counter['assign'], $counter['count']);
}
if (isset($params['print'])) {
@@ -75,6 +75,4 @@ function smarty_function_counter($params, &$smarty)
}
-/* vim: set expandtab: */
-
-?>
+?> \ No newline at end of file