3
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

wordpressの自分用メモ

Last updated at Posted at 2015-01-17

wordpressを使っている上で出て来た問題への対処メモ

サイトアドレスを変更する

サイトアドレスを変更するには管理ページから>一般設定へ
いくことで変更できるが、訳あってそこからの変更が出来ないため別の方法を探してみた。

DBのsiteurlを書き換える
サイトアドレスはDB内のwp_optionsテーブル、option_idが'1'のoption_valueに保存されていた。

mysql> select * from wp_options where option_id = '1';
+-----------+-------------+-------------------------------+----------+
| option_id | option_name | option_value                  | autoload |
+-----------+-------------+-------------------------------+----------+
|         1 | siteurl     | http://exsample.com | yes      |
+-----------+-------------+-------------------------------+----------+
1 row in set (0.00 sec)

UPDATEすることで変更できた。

update wp_options set option_value = 'http://hogehoge.com' where option_id = '1';
3
3
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
3

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?