Where to change wordpress wp-cofing.php location? How is possible that in EE wp-config.php is out of public_html?

Where to change wordpress wp-cofing.php location? How is possible that in EE wp-config.php is out of public_html?

I see in ftp its 1 level up from index.php but since i have my wordpresses in subdomains then i want to put wp-config.php 2 levels up , therefore where to change that config.php is not 1 level but 2 levels higher?

From the official WordPress documentation: https://codex.wordpress.org/Editing_wp-config.php

NOTE: Since Version 2.6, wp-config.php file can be moved to the directory directly above the WordPress install directory.

That’s how it’s possible.

As to whether or not doing so has any security benefit, see this lengthy StackExchange debate: Is moving wp-config outside the web root really beneficial?

Finally, in EE, the configuration file should be above the htdocs directory… eg /var/www/domain.com or /var/www/SUB.domain.com

1 Like