新增一個虛擬站點,zerg.ccc
主要有三步。
1. sudo vi /private/etc/hosts;
2. sudo vi /private/etc/apache2/extra/httpd-vhosts.conf
3. sudo apachectl restart;
沒有報錯。
但訪問:zerg.ccc 無法訪問。
而且,以前其他的虛擬網站都不能訪問了。
很可能是 httpd-vhosts.conf 裏面寫錯了。
終端命令: $ sudo /usr/sbin/httpd -k start ,果然問題出現了
AH00526: Syntax error on line 735 of /private/etc/apache2/extra/httpd-vhosts.conf:
Invalid command 'iServerName', perhaps misspelled or defined by a module not included in the server configuration
正是單詞寫錯!
參考:http://blog.csdn.net/lovenjoe/article/details/50333767
學習編程,就是不斷解決問題的過程。學習改變命運。技術成就夢想!
---------- 招募未來大神 -----------------------
如果您有利他之心,樂於幫助他人,樂於分享
如果您遇到php問題,百度且問了其他羣之後仍沒得到解答
歡迎加入,PHP技術問答羣,QQ羣:292626152
教學相長!幫助他人,自己也會得到提升!
爲了珍惜每個人的寶貴時間,請大家不要閒聊!
願我們互相幫助,共同進步!
加入時留言暗號,php,ajax,thinkphp,yii...