xgdd1987 发表于 2011-5-29 21:41:55

救命啊 大侠进来

本帖最后由 xgdd1987 于 2011-5-29 21:43 编辑

http://www.yuanjiqiang.com/index.php/welcome/index和
http://www.yuanjiqiang.com/index.php
按道理说 ,是指向的同一个页面, 但是第一个就打不开,第二个能打开 。类似的其他的链接 ,只要在index.php后面有东西的链接都打不开。

请各位给指出是哪里出了问题。。


我在本地调试一点问题都没有,主机是godaddy的主机。CI是2.0的。截止在今天白天以前一直正常,从晚上开始这样的。。

Hex 发表于 2011-5-29 22:23:07

老问题了。。。不支持 PATH_INFO。服务器配置问题。
google godaddy codeigniter 吧。

xgdd1987 发表于 2011-5-30 10:55:47

问题解决,终于长舒一口气!按照 http://codeigniter.com/wiki/Godaddy_Installaton_Tips/ 配置

/*********************************************
hank you to everyone who’s posted on Godaddy installation issues.

Having just struggled with this issue myself, this seems to be the shortest path to proper performance on Godaddy.This is entirely based on other people’s posts but, I didn’t really see this all in one place so I thought I do just that.

In config.php:

$config['index_page'] = "index.php?";
$config['uri_protocol'] = "QUERY_STRING";

I’ve successfully implemented this on GoDaddy without using “index.php?” as the index page.This is helpful when using anchor() in the URL helper to create links. Even with htaccess removing the index.php, anchor() will still put in what you have set as an index page.

You should now be able to access everything as such:

http://yourdomain.com/index.php?controller/action/etc

Once you get to a point where you want to hide the ‘index.php?’ paste this into your .htaccess file:
以下是隐藏index.php的方法

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?$1

You should now be able to access everything as such:

http://yourdomain.com/controller/action/etc

The .htaccess file must be in Unix LF only style. If you use Notepad or Wordpad and upload an .htaccess file in CR/LF style it won’t work.

Hope this is helpful.


***************************************************/

页: [1]
查看完整版本: 救命啊 大侠进来