RE: [SMARTY-DEV] Quick Question

From: Date: Mon, 24 Mar 2003 19:57:51 +0000
Subject: RE: [SMARTY-DEV] Quick Question
References: 1  Groups: php.smarty.dev 
Request: Send a blank email to php-smarty-dev+get-1008@lists.php.net to get a copy of this message
Find and replace is not a nice option because it will force developers to remember to write an awful if statement for each display, it's just nasty. How can I do it extending the Smarty class? -----Original Message----- From: aztek@box.sk [mailto:aztek@box.sk] Sent: Monday, March 24, 2003 4:38 PM To: luis@fuegolabs.com Subject: RE: [SMARTY-DEV] Quick Question > Ok, ok I deserve it :-) > The idea is that I have a zillion > $smarty->display('foo.tpl'); lines and I don't want to change > them, I want display to search for templates first in > templates/$user/template.tpl and > then in templates/$user/template.tpl > Which is the best approach? Is there any way to change the default > file: resource? Other method? You could extend the class and use aggregateion which would require only changing a few lines or Find and Replace :)

« previous php.smarty.dev (#1008) next »