WordPress exec() function is disabled require cloud-based optimize


Restarting PHP-FPM service for Apache

If you've seen a warning about exec() being disabled, you may wonder, "why would anyone disable exec?"
The simple answer is that exec can represent a security problem. It is very difficult to use the exec function correctly without opening up security holes. Thus many web hosts prefer not to trust random guys on the Internet to use exec correctly. Anything that is sent to the exec function needs to be sanitized, and escaped, and it isn't always easy to remember that. Indeed, it is something that I regularly have to check for in EWWW IO's code.
So, can you enable 'exec'? That depends greatly on your hosting environment. If you manage your own server, it is as simple as removing 'exec' from the disable_functions setting in your php.ini file. If you leave that arduous task to your web host, then you cannot override it with a custom php.ini. If exec is disabled at the server level, the only one who can enable it is the "system administrator". In other words, you're at the mercy of your web host here. Ask them, very nicely, if they will enable the exec function so that you can use the EWWW Image Optimizer to make your images smaller, use less space, and less bandwidth.