【问题标题】:Joomla nginx rewriteJoomla nginx 重写
【发布时间】:2015-06-12 11:06:21
【问题描述】:

我在一个目录上有很多 joomla 网站。我从 apache 转移到 nginx。但是现在我在 nginx 上重写有问题。我需要所有在 subdir 中的 joomla 都可以像 public_html/ 中的第一个 web 一样使用 rewrite 。它可以只为一个人工作。有没有可以在所有子目录上设置使用重写的解决方案?

这是来自启用站点的我的 hostname.conf 文件。

当我为一个网络重写时

  location / {
     expires 1d;
     try_files $uri $uri/ /index.php?$args;
  }

或子文件夹中的某个:

  location /test/test/test/ {
     expires 1d;
     try_files $uri $uri/ /test/test/test/index.php?$args;
  }

但我需要重写,以便所有 joomla 文件夹都可以在所有目录中工作。因为我的文件夹中有很多 joomla,而且我需要所有的 rewrite mod。我需要解决方案。

【问题讨论】:

    标签: .htaccess mod-rewrite nginx joomla rewrite


    【解决方案1】:

    如果你还没有关注,试试这个,这是一个很好的 wiki 关注 https://docs.joomla.org/Enabling_Search_Engine_Friendly_%28SEF%29_URLs_on_Nginx

    【讨论】:

    • 这是一个网络。我的重写适用于这个规则,但我在子目录中有更多的 joomla。所以他们不工作,因为它写在位置只看到/(第一个目录)
    • 得到你。现在也不知道该怎么做。 :(
    猜你喜欢
    • 1970-01-01
    • 2012-06-05
    • 2013-09-28
    • 2013-03-09
    • 1970-01-01
    • 1970-01-01
    • 2014-05-14
    • 2012-01-29
    • 2014-08-09
    相关资源
    最近更新 更多