Codeigniter application创建应用目录后入口文件index.php应如何改写?
----application
-------admin
-----------cache
-----------config
-----------controllers
-----------core
-----------errors
-----------helpers
-----------libraries
-----------model
-----------views
-------home
-----------cache
-----------config
-----------controllers
-----------core
-----------errors
-----------helpers
-----------libraries
-----------model
-----------views
-----system
-----public (root目录)
-----------admin.php
-----------index.php
我现在前台是http://www.ci.com
后端是http://www.ci.com/admin.php 必须要把.php后缀加上才可以正常访问
public目录可否放个公用的config.php 来指定默认访问的模块和手动载入访问的模块???
两个入口文件index.php前台 admin.php后台 .htaccess 只有一个,现在.htaccess里写的是
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
#RewriteRule !.(js|ico|gif|jpe?g|bmp|png|css)$ index.php [NC,L]
RewriteRule ^(.*)$ index.php [L,E=PATH_INFO1]
http://www.ci.com默认进入的是前端,我现在想http://www.ci.com/admin 进入后端,现在是要这样写
http://www.ci.com/admin.php 加上后缀才可以正常访问,.htaccess里要如何写???
这是apache的 linux的重写规则又有什么不一样?