php url 重写问题

l2x11 2008-10-20 04:22:24
在.htaccess文件中这样写的:
RewriteEngine on
RewriteRule ^testpost\.html$ /testpost.php

抱下面的错误:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, 123 and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.


--------------------------------------------------------------------------------

Apache/2.2.2 (Win32) PHP/5.1.4 Server at localhost Port 80

请问我那里写错了啊?
...全文
67 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
剑心永远OK 2008-10-21
  • 打赏
  • 举报
回复
在httpd.conf里面去掉#LoadModule rewrite_module modules/mod_rewrite.so前面的#号
RewriteEngine on
rewritebase /
RewriteRule ^(testpost)\.html$ $1.php
l2x11 2008-10-21
  • 打赏
  • 举报
回复
现在没有报错了
但是没有实现重写的功能是怎么回事啊?
高人请指点
iasky 2008-10-20
  • 打赏
  • 举报
回复
apache的配置中

<Directory />
Options Indexes FollowSymLinks
AllowOverride All
</Directory>
剑心永远OK 2008-10-20
  • 打赏
  • 举报
回复
看看apache错误日志咯。

21,882

社区成员

发帖
与我相关
我的任务
社区描述
从PHP安装配置,PHP入门,PHP基础到PHP应用
社区管理员
  • 基础编程社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧