XAMPP 不会运行 php [英] XAMPP won't run php
问题描述
我已经在 32 位 Windows xp 机器上安装了 XAMPP.他们在 localhost 上的启动页面看起来不错,但我无法运行自己的 php echo 测试.它们只显示代码,而不显示页面本身.我试过将我的文件放在他们目录中的不同位置,希望能有所作为.我也尝试过其他免费服务器但没有成功,但后来删除了它们.我机器上的本地主机在哪里(?)?非常感谢任何帮助,谢谢.
I've installed XAMPP on a 32-bit windows xp machine. Their splash page at localhost looks fine, but i can't get my own php echo tests to run. They only display the code, not the page itself. I've tried putting my files in different places in their directory hoping something will work. I've also tried other free servers with no luck, but have since removed them. Where(?) is localhost on my machine? any help greatly appreciated, thanks.
推荐答案
XAMPP 通常将 Web 可访问文件存储在 htdocs
文件夹中.找到它并在 local/path/to/htdocs
所在的位置添加 http://localhost/
,如果 XAMPP 正在运行,它应该可以工作.
XAMPP usually stores the web-accessible files in an htdocs
folder. Find this and prepend http://localhost/
where local/path/to/htdocs
would be, and if XAMPP is running, it should work.
因此,在 c:\xampp\htdocs\test.php
中命名和找到的文件(在 Windows 中)将是 http://localhost/test.php
.
So a file (in Windows) named and found in c:\xampp\htdocs\test.php
would be http://localhost/test.php
.
参见:http://www.apachefriends.org/en/常见问题解答-xampp-windows.html#startpage
这篇关于XAMPP 不会运行 php的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!