【问题标题】:ISS ReWrite - SEO friendly URL to Dynamic PageIIS ReWrite - 动态页面的 SEO 友好 URL
【发布时间】:2015-12-10 19:02:57
【问题描述】:

我想使用 ReWrite 来使用指向动态 url 的 SEO 友好 url。

例如:

我想要 SEO 友好的 URL:www.example.com/1/Bird/

从动态 URL 中调出内容:www.example.com/painting-details.cfm?ID=1&Type=Bird

这是我在 .htaccess 文件中尝试过的 ReWrite,但没有成功:

    RewriteEngine on
    RewriteRule /(.*)/(.*)/$ painting-details.cfm?ID=$1&Type=$2

非常感谢任何帮助。

【问题讨论】:

    标签: .htaccess mod-rewrite dynamic url-rewriting seo


    【解决方案1】:

    只需要去掉第一个斜线。 .htaccess 应该是:

        RewriteEngine on
        RewriteRule (.*)/(.*)/$ painting-details.cfm?ID=$1&Type=$2
    

    【讨论】:

      猜你喜欢
      • 2010-12-24
      • 1970-01-01
      • 1970-01-01
      • 2014-12-02
      • 2018-09-20
      • 2016-03-21
      • 2012-09-25
      • 2012-07-22
      • 2016-05-17
      相关资源
      最近更新 更多