When changing my theme in a subdirectory it is also affecting the root directory
-
Hey!
I’m having complications copying WordPress from a root directory into our /new directory so I can work on the new site without affecting the current site on root.
Steps:
1. Copied all the files from root to /new
2. Tried logging into /new/wp-login.php to get to Settings>General and change the URLs, but it didn’t work. Received an error in the browser.
3. Found information on editing /new/wp-config.php by adding the two lines:/** WordPress Move into /new Directory */
define (‘WP_HOME’,’https://www.example.com/new’);
define (‘WP_SITEURL’,’https://www.example.com/new’);4. Ability to login from the /new directory is now successful.
5. Went to change the Theme, but it also affects the root them.
6. Edited .htaccess by adding /new:# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /new
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /new/index.php [L]
</IfModule>
# END WordPress7. Tried adding /new to /new/index.php, but this returned a fatal error:
/** Loads the WordPress Environment and Template */
require(‘./new/wp-blog-header.php’);8. Stopped fooling around as I may simply have an issue with the database itself, and should probably create a new one. Just not sure what to do or where to go from here.
Can someone please help? I cannot seem to find the answers in the codex or I simply all over the place requiring some focus on the steps that I am taking. Thanks in advance to you super helpers! ??
- The topic ‘When changing my theme in a subdirectory it is also affecting the root directory’ is closed to new replies.