891人加入学习
(2人评价)
Linux网络操作系统常见服务的安装与配置

基于VMWARE15和红帽7Linux(RHEL7)

价格 免费

1.安装php

yum install "*php*" -y

 

2.配置httpd.conf支持php的解析

①UltraEdit定位到/etc/httpd/conf/httpd.conf

②找到“Include conf.modules.d/*.conf”,

在下面一行添加“LoadModule php5_module modules/libphp5.so

③找到“AddType application/x-gzip .gz .tgz”在下面一行添加:

AddType application/x-httpd-php .php

AddType application/x-httpd-php-source .phps

设置index.php默认首页

修改

“DirectoryIndex test1.html index.html”为“DirectoryIndex index.php test1.html index.html”

⑤重启httpd服务

systemctl restart httpd

 

3.添加index.php网页

①cd /var/www/html

②touch index.php

③用UltraEdit编辑新建的index.php:

<?php     

phpinfo();

?>

④浏览器内测试连接:http://192.168.31.120:8080/ ,显示php页面。

[展开全文]

授课教师

专注Unity的VR开发

课程特色

下载资料(1)
视频(26)

学员动态