Last Updated: November 21, 2018
·
1.034K
· nsteiner

Let Apache/PHP modify folder/files

I used this to enable a php script to modify folders/files on a local instance of a website that used MAMP on Mac Mavericks OS to do PHP. In this case, it was using Kirby as a CMS, and it's Plugin panel needed this level of access.

sudo chmod -R +a '_www allow read,write,delete,add_file,add_subdirectory,file_inherit,directory_inherit' ~/path/to/site

Learned from: http://francoisdeschenes.com/2013/02/26/enable-write-permissions-for-apache-built-into-mac-os-x

Have a fresh tip? Share with Coderwall community!

Post
Post a tip
Did you know?

PHP applications still send a browser full of JavaScript. Hardening the server does not inventory the payment, analytics, and plugin scripts that run after the HTML is delivered.

Security insights from Cside