Warn on failed templates_c write
Overview
I think this is a problem that we've all faced at some point or another, but experienced implementers know how to fix this, and newbies get caught. When some of your templates_c
files are owned by a user that's not the user running PHP, Civi silently fails in weird and wonderful ways.
Reproduction steps
- Recursively
chown
yourtemplates_c
folder such that the PHP user doesn't have write access.
Current behaviour
Parts of the Smarty forms fail to render.
Expected behaviour
Some sort of warning that there's a permissions issue on the templates_c
folder.
I don't mind doing this if it gets "Concept Approved", though admittedly I've never dug that far down. I'm worried that Smarty isn't going to bubble up an exception, but it's worth a look.