Creating a Website Archive Manually
To manually create a DesktopServer compatible .zip file, please follow the instructions below. You can use this method in lieu of DesktopServer’s native Export feature. A typical WordPress website consists of two major components: 1) The website files that make up your website and 2) The database that holds your website’s posts, pages, themes and plugin settings. You will need both components to have a complete backup of your WordPress website.
1) Copy Your Website Files
- You need to copy your WordPress website files to a safe location, such as your desktop.
- By default, when you create a website in DesktopServer, it places these files inside a folder of the same name as your website (i.e. a folder called “www.example.dev”) at your Documents/Websites folder.
- Use Finder (on Mac) or Explorer (on Windows) to navigate to your website folder (i.e. Documents/Websites/www.example.dev) and copy the folder to your desktop.
- Once you have a “www.example.dev” folder on your desktop (or another safe location), you will need to obtain your website’s database in a portable format.
2) Locate Your Database
- Next, open your web browser and visit http://127.0.0.1/phpmyadmin.
- All of your website databases will appear on the left hand side.
- When DesktopServer creates or imports a new WordPress website, it chooses a name based on the first few characters of your website’s domain name, followed by ‘db’ and a few random characters. For instance, the website www.example.dev might have a database name of ‘exampleDBxyz123′. You can be absolutely sure by checking your website’s wp-config.php file for the line that defines the DB_NAME value.
- When you find your database, click the link on the left hand side.
// ** MySQL settings - You can get this info from your web host ** // /** The name of the database for WordPress */ define('DB_NAME', 'scarroll_postmy1');
3) Export the Database
- Locate and click the “Export” option after selecting your WordPress database in phpMyAdmin.
- The “Export” option can be found as a dedicated menu/tab item at the top of the webpage.
- From the Export tab, you’ll be presented with two options 1) Quick or 2) Custom. In both cases you will want to ensure that the format option is set to SQL.
- In most cases, you can proceed with the easy Quick export option. If you have a larger website, it maybe more efficient to select the Custom export option and click “neither of the above” from the data dump options section.
- Click the Go button to download the database SQL dump file.
- After downloading the file, rename it to database.sql and move it to your safe copy of your website files, i.e. within the “www.example.dev” folder on your desktop.
- The database.sql should be in the same location as the first instance of your index.php file in your website folder. Now you may zip the folder by simply right-clicking it (Cntrl+Click on Mac), followed by the pop-up menu Send To -> Compressed (zipped) folder on Windows or Compress folder on Mac.
You now have a portable zip file containing your entire WordPress website and accompanying database.
This file can then be kept for safe keeping or for import back into DesktopServer using DesktopServer Premium’s Import option. You may also use this file as a blueprint for creating new websites.