Smarty Forum Index Smarty
The discussions here are for Smarty, a template engine for the PHP programming language.

DIRECTORY_SEPARATOR issues and "_cache_paths_file

 
Post new topic   Reply to topic    Smarty Forum Index -> Bugs
View previous topic :: View next topic  
Author Message
luigi
Smarty n00b


Joined: 14 Jun 2003
Posts: 2

PostPosted: Sat Jun 21, 2003 9:41 am    Post subject: DIRECTORY_SEPARATOR issues and "_cache_paths_file Reply with quote

Hi,
I'm using Smarty since a long time, and I've always found it *great*.
These days though I'm having problem with a client's ISP, which
runs Windows+IIS on a shared host.
There are some path issues with current CVS Smarty, which can
cause some problems in a shared host.

First, every now and then you've hard-coded the directory separator
as '/' instead of using the proper constant. After a quick search,
I tracked down where it happens:
- search for the string "core/core" and replace with
"core'.DIRECTORY_SEPARATOR.'core".
- search for '/' (including single-quotes) and replace with
"DIRECTORY_SEPARATOR" (without quotes).

Second - and this one is tricky - the "_cache_paths_file" var
is set on the first line of Smarty constructor, BEFORE the
custom "compile_dir" can be set, so the default value of
"templates_c" is taken instead. This can cause Smarty to
fail working as expected on shared hosts where there's only
a world-writeable directory, and it's usually different than
"templates_c"


I Hope I helped.
Best regards


Last edited by luigi on Wed May 05, 2010 10:59 pm; edited 2 times in total
Back to top
View user's profile Send private message
boots
Administrator


Joined: 16 Apr 2003
Posts: 5611
Location: Toronto, Canada

PostPosted: Wed Jun 25, 2003 5:35 am    Post subject: Reply with quote

Hi Luigi.

Thanks for your post! You may or may not already do so, but I suggest you post CVS related bugs at the dev mailing list. In particular, these comments are interesting as you are talking about a feature that Monte added only a few days ago Smile I'm sure your points would be very much appreciated there.

http://marc.theaimsgroup.com/?l=smarty-dev (also at http://news.php.net/group.php?group=php.smarty.dev)

Thanks again!
Back to top
View user's profile Send private message
mohrt
Administrator


Joined: 16 Apr 2003
Posts: 7367
Location: Lincoln Nebraska, USA

PostPosted: Wed Jun 25, 2003 4:03 pm    Post subject: Reply with quote

These issues are already addresses, FYI Wink
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Smarty Forum Index -> Bugs 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