Miscellaneous
  Home arrow Miscellaneous arrow Smarty for Beginners
Codewalker Forums 
  Tutorials  
Database Articles  
Miscellaneous  
Navigation Usability  
PEAR Articles  
Programming Basics  
Server Administration  
XML Tutorials  
  Reviews  
Database Book Reviews  
Linux Book Reviews  
Miscellaneous Reviews  
PHP Book Reviews  
PHP Software Reviews  
Server Admin Reviews  
SQL Tool Reviews  
  Code Gallery  
Content Management Code  
Contest Code  
Counters Code  
Database Code  
Date Time Code  
Discussion Board Code  
Email Code  
File Manipulation Code  
GUI Code  
Link Farm Code  
Miscellaneous Code  
Search Code  
Site Navigation Code  
User Management Code  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
Download TestComplete 
Forums Sitemap 
Weekly Newsletter 
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
MISCELLANEOUS

Smarty for Beginners
By: Hermawan Haryanto
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 98
    2003-12-28

    Table of Contents:
  • Smarty for Beginners
  • File Creation
  • The Basics
  • What about accessing a database?
  • Some fun stuff

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Smarty for Beginners


    (Page 1 of 5 )

    Join Hermawan as he shows you the basic of the Smarty templating system.

    With this tutorial I aim to explain how to use the Smarty Template Engine in the simplest terms so even beginning coders of PHP can understand how to use it as their primary template engine.

    By reading this tutorial I presume that all of you have the idea of what Smarty can do for you and how it is an amazing template engine which has speed, portability and stability.

    Getting Started

    The first thing you need to do is download the distribution from the download section on its official site. Save it on your computer then unzip it somewhere in your harddrive. There is a folder named "libs" on your extracted files. Upload that "libs" folder on your webhosting account and rename it as "smarty".

    Next, create a sub folder on your web directory; let's say your created subfolder is "smartyrules", so now you can access that folder using your browser by typing this address http://www.domain.com/smartyrules.

    Inside that folder you should create another two subfolders, called "html" and "compile". I'll explain to you later why this is necessary. If you use a *nix distribution then you need to CHMOD 777 to the folder "compile", but if you use Windows then you won't need to do that.

    More Miscellaneous Articles
    More By Hermawan Haryanto


       · and comming from me, "the smary expert", that must be something...
       · Yes, It's very important tutorial added to so many important ones we always read on...
       · I've used Smarty for two years totally incorrectly and appreciate a beginner's...
       · how about a sequel?
       · I liked the article, It is very useful,Can u send further details of it.I have...
       · Call me dense........but I have tried to get Smarty installed on my Win2K box...
       · What was the error message or something for clue. We can't help you if there are no...
       · Sorry - my mistake. Here are the two messages.Parse error: parse error,...
       · I re-read the tutorial and I saw that on line 12 in libs.inc.php would be this...
       · That did the trick - thanks very much for your reply.I never tried switching the...
       · how to connect mysql tables through php codings?
       · Is there an extension to smarty that will create external stylesheets (*.css...
       · simple jadi cepet ngerti.trims..;)
       · Hi,Nice article like many others on codewalkers.com ! However I'm not really...
       · For those who are interested you can get the solution of the exercice at...
       · I have been asking this same question for some time.I have used PHPLib a pretty...
       · I do not have an html folder in my "smartyrules" folder. I don't see it in other...
       · HiProbems are1)lib.inc.php - define ("SMARTY_DIR",...
       · great tutorial dude....had 3 days to learn a new architecture and to develop...
       · Friend, Just give the relative path or full path to where the folder...
       · It is a simple and informative tutorial about smarty
       · Thank you Hermawan Haryanto for providing such an easy way to start smarty.A good...
       · Hi, I'm Karen from Venezuela, maybe you'll see that my english isn't so good, but I...
       · Im getting error when I try to display page. It doesn't tell us how to upload...
       · But what is smartyu?
       · Nice tutorial, keep it up. There is this other tutorial about smarty templating that...
     

    MISCELLANEOUS ARTICLES

    - Shell Script Writing
    - Loops in the UNIX Shell
    - The Test in the UNIX Shell
    - Data Streams and the UNIX Shell
    - Control Mechanisms of the UNIX Shell
    - Variables Within the UNIX Shell
    - The Shell and UNIX
    - In Detail: UNIX File Systems
    - Rights Management in UNIX
    - UNIX File Systems
    - The Terminal in UNIX
    - Operating Systems and UNIX
    - Fedora 10 Released
    - Stopping CSRF Attacks in Your PHP Applicatio...
    - Quick and Dirty AJAX Tutorial





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
    Stay green...Green IT