测试代码:
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
</head><body>
<?php
echo "hello world!"
?>
</body>
</html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
</head><body>
<?php
echo "hello world!"
?>
</body>
</html>
如果不是用的80端口 127.0.0.1:端口/你的php文件
或修改apache的httpd.conf 中的 DocumentRoot "D:/PROGRAM" 重启下apache
你确定你本机可以访问php文件?