【发布时间】:2016-04-29 09:25:49
【问题描述】:
我有几个问题。 例如,在我的网站中,我有一个这样的链接:
localhost/ecom/index.php?pages=1&title=quem-somos
索引文件检查GET['pages'] 的id,并根据来自db 的信息分配两个变量:$static_id 和$static_title。
如何配置 .htaccess 以将此链接“转换”为:
localhost/ecom/quem-somos
当.htaccess 写好后,我的href 应该是这样的:
localhost/ecom/quem-somos
或者,应该是这样的:
localhost/ecom/index.php?pages=1&title=quem-somos
并且网址被转换为对 SEO 友好的网址?
对不起,如果这里有一些愚蠢的问题,我已经阅读了一些博客文章但仍然无法弄清楚。
【问题讨论】: