php apache目录权限设置win,win下如何配置apache+php使user目录能运行php脚本

我的apache+php 安装在C:\Program Files\LocalHost目录下,主目录doc_root也在这个目录下面,我已经配置好在主根目录,能运行各种php脚本没有问题。但是,现在我想配置用户目录,使得用户目录也能执行php脚本。我的配置方法是:

文件:php.ini

user_dir =D:\Downloads\User\Userdir

(并在userdir下建立sisy目录,作为单个的用户目录,并在下面建立了两个文件:index.php、test.htm)

文件:httpd.conf

因为主目录已经配置成功,运行正常,此处略。

文件:httpd-userdir.conf

UserDir "D:/Downloads/User/Userdir"

Options Indexes FollowSymLinks

AllowOverride None

Order allow,deny

Allow from all

但是,我打开http://localhost:86/~sisy/test.htm http://localhost:86/~sisy/test.htm 正常,打开http://localhost:86/~sisy/ http://localhost:86/~sisy/ 失败,提示找不到网页。出错时日志如下:

error.log

[Tue Aug 25 18:01:28 2009] [notice] Child 740: Exit event signaled. Child process is ending.

[Tue Aug 25 18:01:29 2009] [notice] Child 740: Released the start mutex

[Tue Aug 25 18:01:30 2009] [notice] Child 740: All worker threads have exited.

[Tue Aug 25 18:01:30 2009] [notice] Child 740: Child process is exiting

[Tue Aug 25 18:01:30 2009] [notice] Parent: Child process exited successfully.

[Tue Aug 25 18:01:35 2009] [notice] Apache/2.2.11 (Win32) configured -- resuming normal operations

[Tue Aug 25 18:01:35 2009] [notice] Server built: Dec 10 2008 00:10:06

[Tue Aug 25 18:01:35 2009] [notice] Parent: Created child process 420

[Tue Aug 25 18:01:35 2009] [notice] Child 420: Child process is running

[Tue Aug 25 18:01:35 2009] [notice] Child 420: Acquired the start mutex.

[Tue Aug 25 18:01:35 2009] [notice] Child 420: Starting 64 worker threads.

[Tue Aug 25 18:01:35 2009] [notice] Child 420: Starting thread to listen on port 86.

access.log

127.0.0.1 - - [25/Aug/2009:18:01:38 +0800] "GET /~sisy/test.htm HTTP/1.1" 200 17

127.0.0.1 - - [25/Aug/2009:18:01:45 +0800] "GET /~sisy/ HTTP/1.1" 404 25

127.0.0.1 - - [25/Aug/2009:18:02:04 +0800] "GET /~sisy/ HTTP/1.1" 404 25

127.0.0.1 - - [25/Aug/2009:18:19:30 +0800] "GET /~sisy/ HTTP/1.1" 404 25

127.0.0.1 - - [25/Aug/2009:18:21:43 +0800] "GET /~sisy/ HTTP/1.1" 404 25

不知道如何应该如何配置.conf文件和php.ini,才能使得可以在用户目录中运行php脚本?

[ 本帖最后由 yt717 于 2009-8-25 18:28 编辑 ]

本篇文章来源于PHP论坛 文章地址:http://bbs.php.cn/thread-37486-1-1.html http://bbs.php.cn/thread-37486-1-1.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值