2016-10-06 50 views
0

我在本地主機上設置WP網絡。我在窗口,使用統一的服務器,和我設置一個虛擬主機是這樣的:ERR_NAME_NOT_RESOLVED WPMU的第三級域本地主機

<VirtualHost *:${AP_PORT}> 
ServerAdmin [email protected] 
DocumentRoot ${US_ROOTF}/vhosts/themeswp 
ServerName themes.wp 
ServerAlias www.themes.wp *.themes.wp 
ErrorLog logs/themes.wp-error.log 
CustomLog logs/themes.wp-access.log common 
<Directory "${HOME}\vhosts\themeswp"> 
    Options Indexes Includes 
    AllowOverride All 
    Require all granted 
</Directory> 
</VirtualHost> 

加我加這對Windows主機:

127.0.0.1 themes.wp 

如果我去

themes.wp 

一切正常。如果我嘗試第三級域名,如

dummy.themes.wp 

我得到

ERR_NAME_NOT_RESOLVED 

WordPress的網絡告訴我:

Warning! Wildcard DNS may not be configured correctly! 
The installer attempted to contact a random hostname (9f3c9c.themes.wp) on your domain. 
This resulted in an error message: cURL error 6: Could not resolve host: 9f3c9c.themes.wp 

回答

1

權,themes.wp和dummy.themes.wp不同域名

快速的方法:添加dummy.themes.wp給你hosts文件 127.0.0.1 dummy.themes.wp

或安裝任何簡單的DNS服務器,因爲hosts不支持通配符域

+0

我不得不作出子域的一打,我只是寫了他們所有的主機,現在一切正常 – Terix