Templates from the File System

Speed. Another benefit is to be able to edit files from external programs.
No, not what benefit to using templates as files, my question is pertaining to those who are using the file system cache as opposed to APC, XCache, etcetera.
 
No, not what benefit to using templates as files, my question is pertaining to those who are using the file system cache as opposed to APC, XCache, etcetera.
Nope. It's just to allow APC to cache compiled versions.
 
No, not what benefit to using templates as files, my question is pertaining to those who are using the file system cache as opposed to APC, XCache, etcetera.
APC, XCache ... are superior to file cache. But you can enable file cache in any hosting environment whereas you have to ask your hoster to enable APC, XCache for you, and lots of hosters do not allow this.
 
APC, XCache ... are superior to file cache. But you can enable file cache in any hosting environment whereas you have to ask your hoster to enable APC, XCache for you, and lots of hosters do not allow this.
Marcus, thanks for your effort but you really aren't following.
 
Thanks. Was wondering if that small(?) number of us using file system cache would see anything. :)
You should try this and check the performance!

IMO filecache on avarage joe servers/webhosts is often slower, as don't using the cache...
 
when i delete file from xenforo\internal_data\templates i get white page in browser
i think you should make page again if you don't find it in template path ( not only when change template from ACP )

i have idea for that, i will make template folder tmpfs (like ramdisk) in centos linux to put all files in ram ( the problem is, it will deleted if the server restarted )
 
when i delete file from xenforo\internal_data\templates i get white page in browser
i think you should make page again if you don't find it in template path ( not only when change template from ACP )

i have idea for that, i will make template folder tmpfs (like ramdisk) in centos linux to put all files in ram ( the problem is, it will deleted if the server restarted )
If you get that, go to the admin control panel and turn the templates-as-files option off and on again. It will rebuild the file-based templates.
 
i know kier, i do that

but i tell you idea to allow solution for other ideas like what it talk about (moving files to ramdisk)
some thing like replace each include($path) by if(file_exists($path)){include($path)}else{recompile_template}
 
To be honest, storing the files on a RAM disk is going to do very little to speed anything up since the file itself is read once and then your opcode cacher (XCache, eAccelerator, APC, etc.) will compile the PHP file and store it in memory on it's own. Only reading it from disk again if the file changed.

If you don't have an opcode cacher enabled for your web server, I would highly suggest looking into it. That will yield far more speed increase than a RAM disk (the bottleneck would be the time PHP spends recompiling the raw PHP code into something it can run internally... not reading the PHP file from the disk).
 
Top Bottom