From 41cb6435e1ac019420090f393d007a938dfce23a Mon Sep 17 00:00:00 2001 From: mohrt Date: Tue, 2 Jan 2001 21:52:38 +0000 Subject: [PATCH] prepend insert_ to insert tag functions --- Smarty.addons.php | 8 ++++++++ Smarty.class.php | 2 +- demo/index.php | 6 ------ demo/templates/index.tpl | 4 +--- index.php | 6 ------ libs/Smarty.class.php | 2 +- templates/index.tpl | 4 +--- 7 files changed, 12 insertions(+), 20 deletions(-) diff --git a/Smarty.addons.php b/Smarty.addons.php index d5eee926..4c9a767a 100644 --- a/Smarty.addons.php +++ b/Smarty.addons.php @@ -208,4 +208,12 @@ function smarty_func_html_select_date() print $html_result; } +/*============================================*\ + Insert tag functions +\*============================================*/ + +function insert_paginate() +{ + echo "test paginate\n"; +} ?> diff --git a/Smarty.class.php b/Smarty.class.php index 5ff0293c..d3a7c17a 100644 --- a/Smarty.class.php +++ b/Smarty.class.php @@ -494,7 +494,7 @@ class Smarty $arg_list[] = "'$arg_name' => $arg_value"; } - return ""; + return ""; } diff --git a/demo/index.php b/demo/index.php index 28aa61e5..79ceaf6f 100644 --- a/demo/index.php +++ b/demo/index.php @@ -12,10 +12,4 @@ $smarty->assign("Class",array(array("A","B","C","D"), array("E", "F", "G", "H"), $smarty->display("./templates/index.tpl"); - -function test_insert() -{ - print "
this is a test for the insert function
\n"; - -} ?> diff --git a/demo/templates/index.tpl b/demo/templates/index.tpl index bc0acc52..9eb8c468 100644 --- a/demo/templates/index.tpl +++ b/demo/templates/index.tpl @@ -21,6 +21,4 @@ My interests are: ({$FirstName|@count}) -{insert name=test_insert} -{insert name=test_insert} -{insert name=test_insert} +{insert name=paginate} diff --git a/index.php b/index.php index 28aa61e5..79ceaf6f 100644 --- a/index.php +++ b/index.php @@ -12,10 +12,4 @@ $smarty->assign("Class",array(array("A","B","C","D"), array("E", "F", "G", "H"), $smarty->display("./templates/index.tpl"); - -function test_insert() -{ - print "
this is a test for the insert function
\n"; - -} ?> diff --git a/libs/Smarty.class.php b/libs/Smarty.class.php index 5ff0293c..d3a7c17a 100644 --- a/libs/Smarty.class.php +++ b/libs/Smarty.class.php @@ -494,7 +494,7 @@ class Smarty $arg_list[] = "'$arg_name' => $arg_value"; } - return ""; + return ""; } diff --git a/templates/index.tpl b/templates/index.tpl index bc0acc52..9eb8c468 100644 --- a/templates/index.tpl +++ b/templates/index.tpl @@ -21,6 +21,4 @@ My interests are: ({$FirstName|@count}) -{insert name=test_insert} -{insert name=test_insert} -{insert name=test_insert} +{insert name=paginate}