Question
WordPress & plugins can't write files or create directories.
I have a Ubuntu droplet with LAMP installed at setup and I need to host a few different sites & domains there, so the first site’s path is /var/www/sitename.com/public_html, as opposed to the single-install WordPress setup. I also set up phpMyAdmin according to the DO tutorial, then set up the WordPress user and db, and imported the data. Then I copied the WordPress site up and unzipped it in place. At this point the admin and front end work except when needing to write a file or create a directory.
I then followed this tutorial – https://www.digitalocean.com/community/tutorials/how-to-configure-secure-updates-and-installations-in-wordpress-on-ubuntu – to the letter and didn’t hit any snags. It’s still unable to write to files or create directories, though. The admin looks fine but my front-end is completely unstyled because it’s dependent on a LESS plugin that needs to write newly compiled CSS files.
I’m a little lost at this point because I don’t know what else to do beyond setting ownership to wp-user:wp-user and making sure the permissions are set to the correct levels according to the Digital Ocean tutorial. Any ideas?
Thanks!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
×
In your
wp-config.php
file, what is the setting forFS_METHOD
It should be:That setting wasn’t in the wp-config.php file so I added it but WordPress still can’t write & asks for FTP login info.
Sorry about the two unintended answers I posted below. I typed my comment in the wrong box.