虛擬主機中對PHP的特殊設(shè)置
更新時間:2006年10月09日 00:00:00 作者:
虛擬主機設(shè)置
<VirtualHost 127.0.10.10>
ServerAdmin webmaster@hostmachine.com
DocumentRoot /www/virtual.com/htdocs
ServerName www.virtual.com
UserDir /www/virtual.com/htdocs
ScriptAlias /cgi-bin/ /www/virtual.com/cgi-bin/
ErrorLog /www/virtual.com/logs/error_log
CustomLog /www/virtual.com/logs/access_log common</VirtualHost>
目錄設(shè)置
<Directory /www/virtual.com/htdocs>
# 對該虛擬主機設(shè)置是否使用php
php_engine On
# 設(shè)置php出錯信息的調(diào)試級別
php_error_reporting 1
# 設(shè)置是否記錄php出錯日志
php_log_errors On
# 設(shè)置php的出錯日志文件
php_error_log /www/virtual.com/logs/php_error_log
# 設(shè)置一個php線程的最長存活時間
php_max_execution_time 180
# 設(shè)置用戶臨時上載目錄
php_upload_tmp_dir /www/virtual.com/htdocs/tmp
# 設(shè)置包含頭文件
php_include_path /www/virtual.com/htdocs/include
</Directory>
可執(zhí)行目錄設(shè)置
<Directory "/www/virtual.com/cgi-bin">
Options Indexes FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
<VirtualHost 127.0.10.10>
ServerAdmin webmaster@hostmachine.com
DocumentRoot /www/virtual.com/htdocs
ServerName www.virtual.com
UserDir /www/virtual.com/htdocs
ScriptAlias /cgi-bin/ /www/virtual.com/cgi-bin/
ErrorLog /www/virtual.com/logs/error_log
CustomLog /www/virtual.com/logs/access_log common</VirtualHost>
目錄設(shè)置
<Directory /www/virtual.com/htdocs>
# 對該虛擬主機設(shè)置是否使用php
php_engine On
# 設(shè)置php出錯信息的調(diào)試級別
php_error_reporting 1
# 設(shè)置是否記錄php出錯日志
php_log_errors On
# 設(shè)置php的出錯日志文件
php_error_log /www/virtual.com/logs/php_error_log
# 設(shè)置一個php線程的最長存活時間
php_max_execution_time 180
# 設(shè)置用戶臨時上載目錄
php_upload_tmp_dir /www/virtual.com/htdocs/tmp
# 設(shè)置包含頭文件
php_include_path /www/virtual.com/htdocs/include
</Directory>
可執(zhí)行目錄設(shè)置
<Directory "/www/virtual.com/cgi-bin">
Options Indexes FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
相關(guān)文章
PHP PDOStatement::debugDumpParams講解
今天小編就為大家分享一篇關(guān)于PHP PDOStatement::debugDumpParams講解,小編覺得內(nèi)容挺不錯的,現(xiàn)在分享給大家,具有很好的參考價值,需要的朋友一起跟隨小編來看看吧2019-01-01
如何在PHP中使用Oracle數(shù)據(jù)庫(3)
如何在PHP中使用Oracle數(shù)據(jù)庫(3)...2006-10-10
PHP的mysqli_set_charset()函數(shù)講解
今天小編就為大家分享一篇關(guān)于PHP的mysqli_set_charset()函數(shù)講解,小編覺得內(nèi)容挺不錯的,現(xiàn)在分享給大家,具有很好的參考價值,需要的朋友一起跟隨小編來看看吧2019-01-01

