Ok, I’m trying to set up Smarty on my dreamhost account. For some reason, it can’t create the compiled files correctly. Instead of generating what it’s looking for (Files like “%.^2E7^2E76A97E%%index.tpl.php”), it seems to be generating files named “wrt(random string)”, i.e. wrtZ08iWC. This causes open_basedir restriction errors since Smarty isn’t trying to load things with real_path(). Has anyone else had this problem?
Ok, fixed my own problem. PHP wasn’t running as CGI, so smarty files were getting created as dhapache @ 600 permissions. The files couldn’t get renamed properly, which is why they were stuck with the wrt prefix (you can see this in the core_write library in Smarty) instead of being what they should.
So, if you Smarty, remember to turn on PHP as CGI!
I suggest you don’t run PHP as CGI… Ever again.
??? About half the scripts I install don’t seem to run any other way. Could you elaborate?
I am getting the wrt files as well as the %%filenames I’m supposed to have in the compiled templates folder and my PHP is already set to run as CGI. Right now I have 140 files and I can’t delete them. I’ve already tried changing permissions via ftp - doesn’t work. I’ve used $smarty->clear_compiled_tpl() - doesn’t work. Is there anyone out there using Smarty that can help? Or at least tell me how I can delete the files via shell?