0

I installed XAMPP on my Win 10 PC and migrated my wordpress website onto my PC. After migration, only the frontpage works. The other URLs would get a "Not Found". The frontpage is only partially working but I see a page nevertheless.

I have change required data in wp_options. In wp_posts, I changed the URL in column guid. I have also tinkered with apache configurations but with no success. Setting debug to true in wp-config.php does not reveal anything unusual. May I know if you have any suggestions on what else I should tweak?

wp-admin works only if I do localhost/bs/wp-admin instead of localhost/wp-admin . I tried resaving the permalink but the links remain broken.

Thanks buttered_toast. The htaccess made the files visible. Is there another location where I need to change, I spot :

 
include(./php/depth2.php) file not found"

I use PHP Code Snippet (Otherwise known as XYZ PHP) plugin. I have marked up your answers. The themes seems to be defaulting to standard Avada themes.

1
  • About wp-admin, yes, if your wordpress is located in htdocs/bs/, your url will always be with the prefix localhost/bs, so you need to change every old url in the DB to localhost/bs. Other than that I can't help, I can't know what plugins couse problems, i suggest deactivating plugins until your site runs as expected Jul 12, 2021 at 8:34

1 Answer 1

1

When migrating a live site to local you need to do a couple of thing.

  1. update the site url, you can do this in wp_options column (phpmyadmin) or in wp-config.php
  2. You need to find and replace all instances of the old url, you can use better search replace, its a great plugin for exactly that
  3. update the .htaccess to indicate the correct path of your wordpress

That should be enough for most cases

EDIT

enter image description here

Lets say that your wordpress site is located in htdocs/mysite

The RewriteBase and RewriteRule should be like this

RewriteBase /mysite/
RewriteRule . /mysite/index.php [L]
4
  • I did all that you have mentioned but still not working. 1. Made the change in wp_options. 2. I used VIM to search and replace. 3. I don't see any phrase relating to the path. Thanks for trying. Jul 12, 2021 at 7:44
  • Could you include the location (folder name) of your wordpress site in xampp and the code insde the .htaccess Jul 12, 2021 at 7:46
  • I read that it may not be safe to expose my .htaccess . The path to my root is C:\xampp\htdocs\kr . If there is specific block of code in htaccess that you want to know, please tell. Jul 12, 2021 at 7:57
  • 1
    I have added an example for .htaccess, you need to change it accordingly depending on your folders structure Jul 12, 2021 at 8:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.