Smarty Template: My First SmartyTag: smarty, template, test Category: PHP Classespost: 02 May 2008 read: 323 Smarty Template Step By Step Tutorial - Part 3: After create folder needed to operate Smarty template at previous post, in this post, we try to test it. We want to create a page to show simple hello text. Let's do it. First, we do with template file. Create a file named "test.tpl" within template folder. Enter following code:
Next, create a php file named "test.php" within www/test/smarty. Enter following code:
This is our structure:
Now, test it by pointing your browser to http://localhost/test/smarty/test.php. You may get like this:
|
| | Give Your Opinion | Recommend |
|


