问题出现:
在本机windows下创建了html文件与php文件 使得网站起交互作用,可本机没有配置Apache与Nginx,在虚拟机得centos8下配置了php+apache+mysql得环境,但是将实体机得php与html文件移动到 Centos Apache得解析目录下出现

相应得php文件也

自己手动写了简单得php文件,html文件

<?php
echo "autumn";
?>
<html>
<head>
<title>Autumn</title>
</head>
<body>
</body>
</html>

均可以运行


想了好久才怀疑文件本身,是不是可读文件

加上执行权限

chmod a+r html
chmod a+r index.php




可以了哈哈
😎

更多推荐

解决问题Forbidden You don‘t have permission to access this resource.