- NGINX Cookbook
- Tim Butler
- 69字
- 2021-07-03 00:04:23
Subdomains
If you've selected subdomains, your code to put in wp-config.php will look like this:
define('MULTISITE', true); define('SUBDOMAIN_INSTALL', true); define('DOMAIN_CURRENT_SITE', 'wordpressdemo.nginxcookbook.com'); define('PATH_CURRENT_SITE', '/'); define('SITE_ID_CURRENT_SITE', 1); define('BLOG_ID_CURRENT_SITE', 1);
You'll also need to modify the NGINX config as well to add in the wildcard for the server name:
server_name *.wordpressdemo.nginxcookbook.com wordpressdemo.nginxcookbook.com;
You can now add in the additional sites, such as site1.wordpressdemo.nginxcookbook.com, and there won't be any changes required for NGINX.
推薦閱讀
- VMware View Security Essentials
- Learning ROS for Robotics Programming(Second Edition)
- Pandas Cookbook
- Java Web開發(fā)之道
- Scala謎題
- Haxe Game Development Essentials
- Swift語言實(shí)戰(zhàn)精講
- 一塊面包板玩轉(zhuǎn)Arduino編程
- Access 2010中文版項(xiàng)目教程
- 時空數(shù)據(jù)建模及其應(yīng)用
- Django 3.0應(yīng)用開發(fā)詳解
- Secret Recipes of the Python Ninja
- Web編程基礎(chǔ):HTML5、CSS3、JavaScript(第2版)
- Raspberry Pi開發(fā)實(shí)戰(zhàn)
- ASP.NET開發(fā)技巧精講