[PHPTAL] Cache / Compilation behavior
Brice Burgess
bhb at iceburg.net
Thu May 8 19:30:32 CEST 2008
Kornel Lesinski wrote:
> On Thu, 08 May 2008 15:46:42 +0100, Brice Burgess <bhb at iceburg.net>
> wrote:
>
>> From the responses received thus far; it looks like PHPTAL does
>> depend on a user-configured writable directory to compile its
>> templates to?
>
> By default it uses PHP's sys_get_temp_dir() to get writeable directory
> and if that fails, falls back to standard temp paths (supports Windows).
> User doesn't have to configure anything. It should just work on any
> sane setup. The option is there only for insane setups ;)
>
> You can catch (IMHO very rare) case when server doesn't have writeable
> temp dir:
>
> if (!is_dir($phptal->getPhpCodeDestination()) ||
> !is_writeable($phptal->getPhpCodeDestination()))
> {
> // display setup instructions and/or change configuration with
> $phptal->setPhpCodeDestination()
> }
>
Alright. Good to hear that PHPTAL takes advantage of PHP's temp/session
directory by default. I had a feeling it may.
Thanks also for your compile dir write failure detection case!
Now commences the uphill quest of raising the bar to PHP 5 && dropping
smarty. ;) We'll see who wins.
~ Brice
More information about the PHPTAL
mailing list