Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

How to know if my website has Smarty used?

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Tips and Tricks
View previous topic :: View next topic  
Author Message
bimal
Smarty Elite


Joined: 19 Apr 2007
Posts: 423

PostPosted: Tue Feb 03, 2009 3:05 pm    Post subject: How to know if my website has Smarty used? Reply with quote

Please look at the link http://www.zen-cart.com/forum/showthread.php?t=111066 before continuing below...
Zen cart does not use Smarty. Neither does Joomla!

Users who go through the Smarty manual first, see .tpl files in the examples. For example, external threads like http://www.zen-cart.com/forum/showthread.php?t=111066 .

Sometimes, knowing if Smarty or any particular application is being used in a project is necessary in advance, for abandoned projects. Whenever a knowledgeable person quits working with the project you are handed over properly, you should know, what you have. This happens many times in an development house that is growing.

Presence of .tpl files as template does not necessarily mean Smarty. For security and other reasons, you can use any extensions to your templates. In case of zen cart, this tool too used .tpl file as its template. (Writing .tpl seems to be the most nearest match for an extension of a 'TEMPLATE', than any other word.)

Here are more basic ways to identify if your application has use Smarty or not.

First, check for folder names like/similar to: Smarty, compiles, templates, cache, plugins etc.
In a folder, you should see file names with interesting formats, like: %%96^962^962527B1%%menus.inc.php.php. These are the names of the compiled Smarty templates.

The plugins (if custom, and located outside core Smarty), should have file names starting from modifier, function, etc as in: modifier.HTMLSpamFilter.php.

If you can search on the directory listing, then, existence of Smarty's main distribution file is a nice guide. But to be sure that Smarty is really used in the application is to identify the instantiation of Smarty as an object. In the core .php files, you may search a term like, "new Smarty" or "new Smarty()" which guarantees, in many ways to be sure that Smarty is used in the application.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Tips and Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP