본문 바로가기

Software

wordpress 사이트 주소 변경 팁

728x90

#> mysql -u root -p
mysql> use wordpress;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> SELECT * FROM `wp_options` WHERE `option_name` IN ('siteurl', 'home');
+-----------+-------------+--------------------------------+----------+
| option_id | option_name | option_value                   | autoload |
+-----------+-------------+--------------------------------+----------+
|        36 | home        | http://192.168.1.199/wordpress  | yes      |
|         1 | siteurl     | http://192.168.1.199/wordpress | yes      |
+-----------+-------------+--------------------------------+----------+
2 rows in set (0.00 sec)
mysql> update wp_options set option_value='http://192.168.123.108/wordpress' where option_id = 1;
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0
mysql> update wp_options set option_value='http://192.168.123.108/wordpress' where option_id = 36;
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0
mysql> SELECT * FROM `wp_options` WHERE `option_name` IN ('siteurl', 'home');
+-----------+-------------+--------------------------------+----------+
| option_id | option_name | option_value                   | autoload |
+-----------+-------------+--------------------------------+----------+
|        36 | home        | http://192.168.123.108/wordpress  | yes      |
|         1 | siteurl     | http://192.168.123.108/wordpress | yes      |
+-----------+-------------+--------------------------------+----------+
2 rows in set (0.00 sec)
mysql> quit;
Bye

728x90