Manually back up Wordpress
fr:
en:Manually back up Wordpress
es:
pt:
it:
nl:
de:
zh:
ar:
ja:
pl:
ru:
ro:
he:
This article has been created by an automatic translation software. You can view the article source here.
Introduction
Save his Wordpress installation can be convenient when we apply changes directly in the files : en effet, il s'agit de sécuriser ses fichiers, ses plugins et ses thèmes qui pourraient être impactés par une modification. Avec la backup, il ne suffira que de quelques étapes pour remettre WordPress à l'état d'avant les modifications.
Place
Understand how WordPress works
WordPress is a complete solution for creating blogs and sites. Its operation is similar to many "CMS" (content management system). The CMS such as WordPress are developed in PHP and store information, items and parameters in data bases. Generally, these bases are created under MySQL.
There are thus two important points that encompass a WordPress installation : files (le "source code"files, plugins...), and the database (configuration, articles, pages, users...). Nous allons backupr manuellement chaque partie afin de moduler une future réinstallation.
Save WordPress files
If you are a web hosting customer, the simplest solution is to go through your control panel : Select your accommodation from the menu at the top right of the screen, then go to "Web site & Areas". From there, click on the link "httpdocs/"which opens the file manager built into your browser.
From this page, simply check the box "Select all"to the left of the column "Name", then click on "More", and choose "Add to archive". An archive .zip will thus be created, that you can download. It contains all the files of the site, half of the work is thus carried out.
Back up the database
The database usually contains a lot of information : is it that stores all articles and pages in WordPress (title, keywords, content, date of publication...)but also the users (username, password...). Ne pas backupr la base de données est donc bien plus dangereux que ne pas backupr les fichiers installés par Wordpress, qui ne contiennent que le "Visual" (templates, styles, images...) and which are generic (You can very well do a new install of WordPress and recover all of your content from the database, the reverse is not true).
Ainsi, pour backupr la base de donnée, nous allons devoir passer par une interface différente du gestionnaire de fichiers : Always in your hosting package (Select at the top right of the screen for your panel)Click "Websites and domains". Come on in "Database", in the right column, then click on the link "Web Admin" relative to your database.
From there, click on your base, in the column left, and then click "export", on the top menu. The various parameters do not interest us in the immediate future, we'll just click on "Export" : You can see download a .sql file, containing all of our tables. The database is thus downloaded.
Reimport its site
In the case where something goes wrong during your changes in the WordPress files (installation of plugins failed, virus stuck in the topic...), here is the reinstatement of your previous method.{Template:Sauvegarde}}.
In your httpdocs directory/Click "Import", and then select your archive previously downloaded .zip (in the step of the backup WordPress files). The waiting time can be long sometimes depending on the size of the archive.
One time imported, select it, then click "More"and then "Extract the files" : the structure of the site should be fully respected. If the database has not been affected by your previous changes, in this case everything should work. If this isn't the case, that the database is no longer present from the Control Panel, you must reimport your backup :
Create a database by clicking "Add a new database" : give it a name, a user and a password for the user. Once created, go in the "Web Admin" as previously stated : This time, click "Import"Select your previously downloaded .sql file and click "run". Once the load is complete, you should see more information in the left column, are the base tables that were imported correctly.
There is one final change to perform : Update WordPress login information. Indeed, the creation of a new database before importing seen at the last step changes the name of the database, the user and his password. So, you have to edit a file of WordPress in order to provide the new information :
In "Web sites & Areas"back in "httpdocs/". Search for and hover on the file "WP - config.php"and then click "change the rights". Check the first box of "Write"and then click "OK". Back in the file manager, hover over again and choose "Editing in text editor".
In the new window that opens, find the following lines and change their contents so that they coincide with the information in the database :
define('DB_USER', 'ancienne_information'); // l'utilisateur de la base de données créée
define('DB_PASSWORD', 'ancienne_information'); // le mot de passe de l'utilisateur de la base
define('DB_HOST', 'localhost'); // normalement 'localhost', il s'agit de l'hôte
define('DB_CHARSET', 'utf8'); // ne devrait pas être modifié, encodage des caractères de sortie
define('DB_COLLATE', ''); // ne nous concerne pas dans ce tutoriel
After ensuring the coherence of the returned information, click "Save"and then change the permissions again by removing the first box "Write" : It is a security measure.
Your site should now be available.
Conclusion
Ainsi, nous avons ici vu comment backupr manuellement un site fonctionnant avec WordPress : ce tutoriel peut également s'appliquer avec d'autres CMS fonctionnant sous PHP, comme Joomla ou Drupal, à condition d'adapter la dernière partie aux fichiers de ces deux logiciels. Enfin, il est recommandé de fréquemment backupr ses fichiers et ses données afin de ne pas être pris au dépourvu en cas de défaillance du système.
In summary :
- "zipper" all the web files in the folder httpdocs/
- Download the .zip file created
- export the database from Phpmyadmin
Restoration :
- empty folder httpdocs/
- upload the backup in .zip
- extract the backup zip to find the structure of the site
- create a new database + user related
- aller dans Phpmyadmin, importer la base backupr dans la nouvelle créée
- return to httpdocs/, modify the rights of wp - config.php by adding writing
- Edit wp - config.php to match information
- backupr and remove the right of writing on wp - config.php
This article seem useful to you ?
Enable comment auto-refresher