【问题标题】:mod_rewrite migration from apache to lighttpdmod_rewrite 从 apache 迁移到 lighttpd
【发布时间】:2013-03-26 08:50:58
【问题描述】:

如何用 lighttpd 描述同样的事情?

我的 .htaccess:

RewriteEngine On
RewriteBase /
RewriteCond $1 !^(index\.php|style\.css|image|image-small|robots\.txt|sitemap\.xml|favicon\.ico)
RewriteRule ^(.*) index.php [L]

【问题讨论】:

    标签: apache mod-rewrite rewrite lighttpd


    【解决方案1】:

    未测试:

    server.modules = (
        "mod_rewrite"
    )
    
    $HTTP["host"] == "web.com" {
    
        server.document-root = "/var/www/web.com/public_html/"
    
        url.rewrite-once = ( 
          "^(?!index\.php|style\.css|image|image-small|robots\.txt|sitemap\.xml|favicon\.ico)" => "$0"
          "^(.*)" => "index.php"
        )
    
    }
    

    更多信息here

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-02-17
      • 1970-01-01
      • 2010-11-09
      • 1970-01-01
      • 2011-08-24
      • 1970-01-01
      相关资源
      最近更新 更多