- 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.
推薦閱讀
- Python科學計算(第2版)
- Reporting with Visual Studio and Crystal Reports
- Java EE 6 企業級應用開發教程
- Visual FoxPro 程序設計
- Mastering Entity Framework
- Java入門很輕松(微課超值版)
- 零基礎學MQL:基于EA的自動化交易編程
- HTML5 and CSS3 Transition,Transformation,and Animation
- 你不知道的JavaScript(中卷)
- 深入淺出React和Redux
- Java程序員面試筆試寶典(第2版)
- Learning Android Application Testing
- Appcelerator Titanium:Patterns and Best Practices
- Building Scalable Apps with Redis and Node.js
- Python網絡運維自動化