[PHP]怎样在SAE的CodeIgniter项目中隐藏掉index.php

第一步:改动项目根文件夹的config.yaml文件。加入例如以下内容:

handle:
	- rewrite: if(!is_dir() && !is_file() && path~"/") goto "/index.php/%{QUERY_STRING}"

第二步:将application/config/config.php中的$config['index_page']设置为'':

$config['index_page'] = '';

OK。搞定。


posted @ 2017-06-13 11:07  wzjhoutai  阅读(131)  评论(0编辑  收藏  举报