WordPress Multisite – Domain Mapping

As you might already know, this is done via the Edit button for the site. That contains all of the wp-options table rows for that sub-site. I always go through that entire list (it is long) and change all occurances of www.example.com/site1 to www.mydomain.com (the domain name for that subsite).

Many plugins/themes store info in the wp-options table, so you have to check each entry in that subsite edit screen. Then bring up a few pages with the new domain name, and use the F12/Inspector and look at the network tab to ensure that all the requests are to the new domain name.

Note that you may also need to fix any old urls for media entries. I’d use a search/replace plugin (I use the “Better Search and Replace” one) to easily change all www.example.com/site1 to www.newdomain.com . Backup your database first, of course.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)