Can't access sites on localhost (working fine online)
-
Hi,
On my online server I have 2 sites that are working fine on my WP installation, I copied everything (Files and DB) to my local server (XAMPP) to make some theme developments. I can access my main site at
local.maindomain.com
, however, how can I access the other sites (site1 and site2)?This is what I have in my hosts file:
127.0.0.1 localhost 127.0.0.1 local.maindomain.com 127.0.0.1 local.site1.com 127.0.0.1 local.site2.com
This is my vhosts
<VirtualHost *:80> DocumentRoot D:\Webserver_WP ServerName local.maindomain.com <Directory D:\Webserver_WP> Order allow,deny Allow from all </Directory> </VirtualHost> <VirtualHost *:80> DocumentRoot D:\Webserver_WP ServerName local.site1.com <Directory D:\Webserver_WP> Order allow,deny Allow from all </Directory> </VirtualHost> <VirtualHost *:80> DocumentRoot D:\Webserver_WP ServerName local.site2.com <Directory D:\Webserver_WP> Order allow,deny Allow from all </Directory> </VirtualHost>
On the dashboard, if I choose “Visit Site” it tries to get to
local.maindomain.com/site2
but I get a “Object not found!” error.Here’s everything I’ve done, step by step. There’s some ingredient missing on this “recipe”:
1. Sync the WordPress files: Delete all files before upload; 2. Sync the database: Delete all tables before upload new database; 3. Change the following lines on wp-config.php: define( 'DOMAIN_CURRENT_SITE', 'your-local-domain’ ); define( 'SUNRISE', 'off' ); 4. Check the following values on the database: Table: wp_blogs Field: domain Table: wp_site Field: domain Table: wp_sitemeta Field: meta_key > siteurl Tables: wp_options / wp_*_options Field: option_name > fileupload_url Field: option_name > home Field: option_name > siteurl
I’ve been trying to get this solved for a couple of days now, any help is welcome, thanks.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Can't access sites on localhost (working fine online)’ is closed to new replies.