code点火器:从URL删除的index.php [英] code igniter : removing index.php from url

查看:292
本文介绍了code点火器:从URL删除的index.php的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最后经过很多我得到了我的网站正在Godaddy的搜索......现在的问题是删除的index.php 从网址

Finally after a lot of searches I got my site working on Godaddy... now the problem is removing the index.php from the url

我目前的config.php文件有:

My current config.php has:

'uri_protocol' = 'AUTO';
'index_page' = '';

目前.htacess文件:

Current .htacess file:

Options -Multiviews
Options +FollowSymLinks
RewriteEngine on
RewriteBase /base
RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$ /index.php?/$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond $1 !^(index\.php|images|robots\.txt|css)
RewriteRule ^(.*)$ index.php?$1 [L]

我已经竭尽所能从这个链接: HTTP://$c$cigniter.com/forums/viewthread/133292/

I've tried everything from this link: http://codeigniter.com/forums/viewthread/133292/

我可以通过访问的http://base/index.php /控制器/ 的http://底座/控制器/ 给了我404

I can access it using http://base/index.php?/controller/ but http://base/controller/ gives me a 404.

什么我需要做删除的index.php 从网址是什么?

What do I need to do to remove the index.php from the URL?

请有人使用GoDaddy的和CI帮助!

Please some one using godaddy and CI help !!!!

推荐答案

这是一个我用

DirectoryIndex index.php
RewriteEngine on

RewriteCond $1 !^(index\.php|(.*)\.swf|forums|images|css|downloads|js|robots\.txt|favicon \.ico)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ ./index.php?$1 [L,QSA] 

工程于2点

这篇关于code点火器:从URL删除的index.php的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆