我使用以下查询字符串
?前夕= MTkzODMwMjk0OQ ==
根据前夕值的值更改节点主体的内容。
完整网址如下所示:
http://localhost/party/event.php?eve=MTkzODMwMjk0OQ== 我想清理网址,看起来像这样:
http://localhost/party/event.php/eve/MTkzODMwMjk0OQ==
我该怎么做?
答案 0 :(得分:1)
您甚至可以省略.php以使其更加干净
Options +FollowSymLinks
RewriteEngine on
RewriteRule event/eve/(.*)/ event.php?eve=$1
RewriteRule event/eve/(.*) event.php?eve=$
示例网址
http://localhost/party/event/eve/MTkzODMwMjk0OQ/
将转移到
http://localhost/party/event.php?eve=MTkzODMwMjk0OQ==