adj 2007-11-29 21:36
讓一般 User 也能有執行 cgi-bin 的權限
這個設定可以讓一般的 User 也能有執行 cgi-bin 的權限...[code]<VirtualHost 11.22.33.44>
ServerName service.adj.idv.tw
DocumentRoot /home/service
ScriptAlias /cgi-bin/ "/home/service/cgi-bin/"
<Directory "/home/service/cgi-bin">
AllowOverride None
Options +ExecCGI
Order allow,deny
Allow from all
</Directory>
</VirtualHost> [/code]========================================================
如果想讓所有使用者都適用的話...應該可以這樣改...
<VirtualHost 11.22.33.44>
ServerName service.adj.idv.tw
DocumentRoot /home
ScriptAlias /cgi-bin/ "/home/*/cgi-bin/"
<Directory "/home/*/cgi-bin">
AllowOverride AuthConfig
Options +ExecCGI
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
========================================================
如果不想出現 cgi-bin 這個目錄名稱...則可以使用
<VirtualHost 11.22.33.44>
ServerName service.adj.idv.tw
DocumentRoot /home
ScriptAlias / "/home/*/cgi-bin/"
<Directory "/home/*/cgi-bin">
AllowOverride None
Options +ExecCGI
Order allow,deny
Allow from all
</Directory>
</VirtualHost>