Hi Vytis,
Thank you for your reply.
The widgets where disapearing in the back-end, Customizer, and the front-end obviously.
I used the manual method (method of my hosting comp.) to move the site to the staging area, as follows:
Set up a staging or working copy for your WordPress website
Whenever you want to introduce changes to your WordPress website, it is a good idea to test them first. Whether you are adding new themes, new plugins or adding new content, you might want to test everything first. This tutorial will show you how to create a working copy (staging copy) of your WordPress website, which you can work on, while your original website is still online. This tutorial will also be helpful if you want to move your WordPress website to another host.
In this article we are using as an example the website https://ninefortwowebhosting.com/. Make sure you substitute that string with your own domain name when you follow the steps.
Create a new subsite. This will be the address of your staging website.
Now copy your official website to staging so you can start editing. Login to SSH. Execute from ssh root directory:
rsync -rtv www/ subsites/staging.ninefortwowebhosting.com/
This will not be sufficient for your staging copy to work. You also need the database.
You will need certain database details in order to create a backup. Get them from your configuration file by executing the following command:
cat www/wp-config.php | grep DB_
The output will look something like this:
define(‘DBNAME’, ‘ID111111user’);
define(‘DBUSER’, ‘ ID111111user ‘);
define(‘DBPASSWORD’, XXXXXXXXXX);
define(‘DBHOST’, ‘mysql111.hosting.brand.com’);
define(‘DBCHARSET’, ‘utf8’);
define(‘DBCOLLATE’, ”);
Make a copy of your database details.
Download a database backup. Download the dump file via rsync or ftp.
Now create the new database that will be used for the staging copy from the control panel.
You can use this tool https://wpdomainchanger.com/ to edit the URLs from the original WordPress to the staging WordPress. Download the altered database dump.
Import the altered database dump
Now you have to update the wp-config.php file of the staging copy with the new DB details. Open the config file like so:
nano subsites/staging.ninefortwowebhosting.com/wp-config.php
Edit the following strings with the details of the new database you created:
In this string enter your new database name
define(‘DBNAME’, ‘ID111111name’);
In this string enter your new username
define(‘DBUSER’, ‘ ID111111user ‘);
In this string enter your new password
define(‘DB_PASSWORD’, XXXXXXXXXX);
In this string enter your new database host
define(‘DB_HOST’, ‘mysql111.hosting.brand.com’);
Now test if your copy works.
Best Regards,
Staf