【问题标题】:HTTP Error 404.0 - Not Found in IIS for Yii PHPHTTP 错误 404.0 - 在 IIS 中找不到 Yii PHP
【发布时间】:2014-03-26 05:01:14
【问题描述】:

我在 IIS 7.0 中托管了 YII 框架 php 应用程序。我可以查看默认页面,但是当我尝试访问其他页面时出现错误:

HTTP 错误 404.0 - 未找到。您正在寻找的资源已被 已删除、更改名称或暂时不可用。

我知道运行时路径无效,但我找不到解决方案。

【问题讨论】:

    标签: php iis yii


    【解决方案1】:
                1) Download Url Rewriting Extension from:
    

    http://www.iis.net/downloads/microsoft/url-rewrite

                2)Install It then goto IIS Manager-> click on your site-> In Feature View there will be a Url writng icon double click it-> Browse your .htaccess to enable your rules.
    
            3) if you have no .htaccess file create it and paste the following code in it...
    
    
             RewriteEngine on
    
                # if a directory or a file exists, use it directly
                RewriteCond %{REQUEST_FILENAME} !-f
                RewriteCond %{REQUEST_FILENAME} !-d
    
                # otherwise forward it to index.php
                RewriteRule . index.php
        I hope this will work for......
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2017-07-28
      • 1970-01-01
      • 2015-01-16
      • 1970-01-01
      • 1970-01-01
      • 2011-08-29
      • 2016-03-08
      • 1970-01-01
      相关资源
      最近更新 更多