.htaccess 我的htaccess文件中的URL重写错误
大家 我需要重写这个URL.htaccess 我的htaccess文件中的URL重写错误,.htaccess,.htaccess,大家 我需要重写这个URL http://www.mydomain.com/profiles/tutors/index.php?tutorCode=1255&tutorName=Kasun%20Perera&city=Bandarawela 像这样 http://www.mydomain.com/profiles/tutors/1255/Kasun+Perera.html 我用Apache的mod_重写功能尝试了这一点。但我没能达到我预期的结果 下面是我尝试过的代码 Rewr
http://www.mydomain.com/profiles/tutors/index.php?tutorCode=1255&tutorName=Kasun%20Perera&city=Bandarawela
像这样
http://www.mydomain.com/profiles/tutors/1255/Kasun+Perera.html
我用Apache的mod_重写功能尝试了这一点。但我没能达到我预期的结果
下面是我尝试过的代码
RewriteEngine on
对于特定教师:
RewriteRule ^lanka_institute/profiles/tutors/([0-9]+)/([A-Za-z\+\-]+)/([A-Za-z\+\-]+)/$ index.php?tutorCode=$1&tutorName=$2&city=$3
它不工作,然后我可以得到这个错误消息
内部服务器错误
服务器遇到内部错误或配置错误,无法正常运行
无法完成您的请求
请与服务器管理员联系,admin@localhost通知
告诉他们错误发生的时间,以及您可能做的任何事情
这可能是导致错误的原因
有关此错误的详细信息,请参阅服务器错误
日志
如有任何意见,我们将不胜感激
谢谢。检查服务器日志,看看哪里出了问题。+1问得好。请返回并接受答案,以便更多人愿意提供帮助。URL的一部分发生了什么事?@Levon请不要对代码使用块引号。也不要在代码中添加换行符。