How do I create a WP sandbox for development on localhost (raspberry pi 4) without being redirected to the live site?
I bought a WordPress website through Flippa and I need to set up a development area that will let me test changes and updates before I put them on the live site. I am brand new to this so I want to make sure I don't break the existing site. I have set up a raspberry pi 4 with a LAMP setup. The Linux is Buster with Apache2, MariaDB, and PHP 7.3.
I finally figured out how to attach the database to a new WordPress install using PHPMyAdmin to import the existing database into a blank one. I merged the existing source code with the WordPress install in the /var/www/html
folder using the following command. (5469-6696 is the name of the flash drive)
sudo cp -RT /media/pi/5469-6696 /var/www/html
I deleted the wp-config.php
file and started the WP installation. I attached the database to the setup of WordPress and it tells me "You appear to have already installed WordPress. To reinstall please clear your old database tables first."
If I delete the database tables I don't have anything to test with but if I click the login button it takes me to the live site and reentering the IP address of the Pi does the same thing. I want to use the Pi as a local testing server. How do I stop the install from connecting to the live site?