1. 原來主站為:
代碼: 選擇全部
<Directory "/var/www/website">
AllowOverride All
Order deny,allow
</Directory>
2. .htaccess:
代碼: 選擇全部
AuthName "Auth"
AuthType Basic
AuthUserFile /path/apache.passwd
require user username
代碼: 選擇全部
htpasswd -c /path/apache.passwd username
參考資料:
http://www.netadmin.com.tw/article_cont ... 1107080004
http://www.sega.com.tw/bbs/index.php?showtopic=899