CentOS 5.4下配置Apache服务器(3)
来源:未知 责任编辑:责任编辑 发表时间:2013-11-15 19:50 点击:次
#
DirectoryIndex index.html index.html.var
我们按照自己的想法构架一个PHP WEB网站。。。GO。。。
添加了一个index.php ,方便一会我们测试apache支持php,如果找不到,系统会出现redhat的测试页面
#
DirectoryIndex index.html index.php
我们测试把默认网站目录改到root家目录下
第一步,修改DocumentRoot这个位置 1
第二步,修改目录的权限设置 2
重启一下httpd服务
[root@host webphp]# service httpd restart
客户端浏览
现在我们自己建一个PHP页面吧。。。
[root@host webphp]# ll /root/webphp
总计 0
[root@host webphp]# echo hello.This is a php webservers! > /root/webphp/index.php
[root@host webphp]# ll /root/webphp
总计 8
-rw-r--r-- 1 root root 32 02-19 13:58 index.php
我们来看看我们自己建的PHP页面吧。。。
基于LINUX下的基本服务构架都实验过了!但是对于构架好后的正常维护,还需要有更好的环境去努力学习啊。。。
-------------------
相关新闻>>
- 发表评论
-
- 最新评论 进入详细评论页>>