Search
 
SCRIPT & CODE EXAMPLE
 

SQL

wordpress sql change site url

# Check your table prefix
# Change all the tables 

UPDATE wp_options SET option_value = 
replace(option_value, 'oldurl.com', 'newurl.com') WHERE option_name = 'home' 
OR option_name = 'siteurl';UPDATE wp_posts SET guid = 
replace(guid, 'oldurl.com','newurl.com');
UPDATE wp_posts SET post_content = replace(post_content, 'oldurl.com', 'newurl.com');

UPDATE wp_postmeta SET meta_value = replace(meta_value,'oldurl.com','newurl.com');
Comment

change site url wordpress database

options table
1. siteurl
2. home

######## OR ########

// Add to top of wp-config.php
define( 'WP_HOME', 'http://example.com' );
define( 'WP_SITEURL', 'http://example.com' );
Comment

PREVIOUS NEXT
Code Example
Sql :: create table oracle 
Sql :: oracle sql drop index 
Sql :: how remove column in mysql 
Sql :: mysql text to decimal 
Sql :: rename column postgres 
Sql :: postgres install unaccent extension 
Sql :: primary key reset in SQL database 
Sql :: mysql show processlist full query 
Sql :: mssql show database size 
Sql :: linux command line import mysql database 
Sql :: oracle stop job 
Sql :: start mysql server 
Sql :: change varchar length mysql 
Sql :: add super privilege mysql 
Sql :: oracle check table space 
Sql :: MySql get fields of table 
Sql :: how to check data type in sql server 
Sql :: psql: error: connection to server on socket "/tmp/.s.PGSQL.5432" f 
Sql :: mysql date diff in seconds 
Sql :: oracle list invalid password ORA-01017 
Sql :: how to check database size mysql 
Sql :: sql headers delphi 
Sql :: monthname sql 
Sql :: Disabling foreign key checks while performing Sqlalchemy Upgrade 
Sql :: operator does not exist: integer = text 
Sql :: get a list of table names and field names from SQL 
Sql :: sql server roles and users 
Sql :: select insert new table sql server 
Sql :: mysql substract count and distinct count 
Sql :: oracle add month 
ADD CONTENT
Topic
Content
Source link
Name
6+9 =