httpd使用命令
# 启动
service httpd start
# 停止
service httpd stop
参考:https://www.cnblogs.com/jr1260/p/6524665.html
httpd无法解析php语句
现象
web页面将php脚本解析为注释
<?php phpinfo(); ?>
web页面为
<--?php phpinfo(); ?-->
httpd配置
LoadModule php7_module /usr/lib64/httpd/modules/libphp7.so
DirectoryIndex index.html index.html.var index.php
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .php7
AddType text/html .shtml .php
解决办法
<FilesMatch .php$> SetHandler application/x-httpd-php </FilesMatch>