【问题标题】:Expression Engine Does not Work Without index.php? - "?" always required没有 index.php,表达式引擎无法工作? - “?”总是需要
【发布时间】:2016-04-22 09:57:50
【问题描述】:

我们在从网站访问页面时遇到问题。

如下 url 正在构建中 https://www.website.com/index.php/about/ensembles/concert-band

但它总是只显示主页。

但是,当我附加“?” (在 index.php 之后)在 url 中,它显示实际页面。 点赞:https://www.website.com/index.php?/about/ensembles/concert-band

谁能帮我解决这个问题以访问没有“?”的页面- 表达式引擎中是否有任何设置可以启用/禁用?目前,我们托管在 Ubuntu 和 PHP5 上。 - 我们尝试使用强制查询字符串启用/禁用,但无论如何都不起作用。我们也尝试了下面的 .htaccess,但没有运气

<IfModule mod_rewrite.c>

# Enable Rewrite Engine
# ------------------------------
RewriteEngine On
RewriteBase /

# Standard ExpressionEngine Rewrite
# ------------------------------
RewriteCond $1 !\.(css|js|gif|jpe?g|png) [NC]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php/?$1 [L] 

</IfModule>

请建议/建议。

谢谢

【问题讨论】:

    标签: php .htaccess url-rewriting expressionengine


    【解决方案1】:

    尝试移动问号

    /index.php?/$1
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-06-23
      • 2020-04-04
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-03-09
      • 2011-08-05
      相关资源
      最近更新 更多