Forked from gregoirenoyelle/wp-sql-mise-a-jour.sql
Last active
August 29, 2015 14:10
-
-
Save maxperei/ccde8a58a035876c7fd1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Coller la totalite dans champs SQL de phpMyAdmin ## | |
## ATTENTION A NE PAS METTRE DE SLASH A LA FIN DES URL ## | |
# CHANGER URL DU SITE | |
UPDATE wp_options | |
SET option_value = REPLACE(option_value, 'http://www.vieuxsite.fr', 'http://www.nouveausite.fr') | |
WHERE option_name = 'home' | |
OR option_name = 'siteurl'; | |
# CHANGER URL DES GUID (GLOBAL UNIQUE IDENTIFIER) | |
UPDATE wp_posts | |
SET guid = REPLACE(guid, 'http://www.vieuxsite.fr', 'http://www.nouveausite.fr'); | |
# CHANGER LES URL DES CONTENUS DES ARTICLES | |
# (LIEN, IMAGE, DOCUMENT) | |
UPDATE wp_posts | |
SET post_content = REPLACE(post_content, 'http://www.vieuxsite.fr', 'http://www.nouveausite.fr'); | |
# CHANGER LES URL DES DONNEES META DES POSTS | |
UPDATE wp_postmeta | |
SET meta_value = REPLACE(meta_value, 'http://www.vieuxsite.fr','http://www.nouveausite.fr'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment