I've moved my Wordpress files from public_html to a subdirectory public_hmtl/my-site. I've changed my .htaccess in the public_html directory by
RewriteEngine on RewriteCond %{HTTP_HOST} ^my-site$ [NC,OR]
RewriteCond %{HTTP_HOST} ^www.my-site$
RewriteCond %{REQUEST_URI} !my-site/
RewriteRule (.*) /my-site/$1 [L]
I've configured my database and wp-config.php too, to:
define('WP_HOME','');
define('WP_SITEURL','');
define('RELOCATE',true);
But when I want to login per wp-admin the path seems to be like:
wp-login.php?redirect_to=https%3A%2F%2Fwww.my-site%2Fmy-site%2Fwp-admin%2F&reauth=1
Do you have any idea?
Thanks
Kamil
I've moved my Wordpress files from public_html to a subdirectory public_hmtl/my-site.com. I've changed my .htaccess in the public_html directory by
RewriteEngine on RewriteCond %{HTTP_HOST} ^my-site.com$ [NC,OR]
RewriteCond %{HTTP_HOST} ^www.my-site.com$
RewriteCond %{REQUEST_URI} !my-site.com/
RewriteRule (.*) /my-site.com/$1 [L]
I've configured my database and wp-config.php too, to:
define('WP_HOME','https://www.my-site.com');
define('WP_SITEURL','https://www.my-site.com');
define('RELOCATE',true);
But when I want to login per wp-admin the path seems to be like:
wp-login.php?redirect_to=https%3A%2F%2Fwww.my-site.com%2Fmy-site.com%2Fwp-admin%2F&reauth=1
Do you have any idea?
Thanks
Kamil
try this >>
step 1) on wp-config.php
define('WP_HOME','https://www.my-site.com/my-site.com');
define('WP_SITEURL','https://www.my-site.com');
define('RELOCATE',true);
now, on your /index.php change this line: require( dirname( FILE ) . '/wp-blog-header.php' ); to
require( dirname( __FILE__ ) . '/my-site.com/wp-blog-header.php' );