Local Community

Wordpress outside of default folder structure

Can Local be configured to work with WordPress installs that are outside of the default setup/folder structure?

Like if a site is configured to use local-config.php or puts wp-content outside of the wordpress folder

Thanks!

Hi @jmyweb,

Yup!

Your best bet is to use the “Custom” environment so you have access to the conf folder.

Once the site is using Custom, edit the site.conf file inside the site’s conf/nginx folder and change the root option from /app/public to whatever you need it to be. After making the change, restart the site in Local.

How do the steps differ if I’m using Apache? Not seeing anything in the conf/nginx folder.

Also, just to confirm, I’m not trying to change the root directory of the server, I’m trying to configure Local to work with a non-standard configuration of Wordpress where the wp-content folder is up one level from the wordpress root.

( screenshot attached )

Thanks Clay!

Hi @jmyweb,

Sorry for the delay getting back to you!

See https://codex.wordpress.org/Editing_wp-config.php#Moving_wp-content_folder

Yes, I’ve already got WordPress configured like this. I’m asking how to configure Flywheel to work with a non-standard setup outside of the normal root for wp-config, not WordPress itself.

How would I do this? I’m using Apache with Flywheel, not Nginx.

Thanks for your help!

As long as WordPress is configured to use the different wp-content folder, it should work. If the web root is the same then you shouldn’t need to change any settings with nginx or Apache.

Are you running into any errors? If so, please provide them.

Here’s a few things:

  1. It’s not able to pull the current version of wordpress. See screenshot: https://www.screencast.com/t/0k5ANVE8LOs

  2. For db, it’s pulling values from wp-config.php, instead of local-config.php. Not a huge deal, but would be cool if it could grab the credentials from there instead. See screenshot: https://www.screencast.com/t/VgoVhdCYMjX

  3. Is there any way to disable automatic backups on server shutdown? Our db is pretty big and it takes quite a while to back up.

Thanks Clay!!

Hey

I’ve the same problem : I want to move wp-content folder outside the wordpress directory, exactly like jmyweb :

It works globally, except for plugins assets, that return 404 errors, whilst files seems to be on the good folder :

Thanks for your help !