2016-04-05 19 views
3

拡張子名をcodeigniterルートに入れてください(たとえば、.html、.php)、ルーティングに関するドキュメントを読んでください。その種の機能codeigniterルートに拡張子名を追加するには

私はちょうど私のルートは、この

https://localhost/project/route.php 

のように任意のアイデアを見てみたいですか?

ありがとうございます。

答えて

6

config.phpでこれを変更してください。

$config['url_suffix'] = '.html'; //or .php 
4

はい、application/config/config.phpファイルにあります。

私は私の設定を過ぎてコピー/:

/* 
|-------------------------------------------------------------------------- 
| URL suffix 
|-------------------------------------------------------------------------- 
| 
| This option allows you to add a suffix to all URLs generated by CodeIgniter. 
| For more information please see the user guide: 
| 
| http://codeigniter.com/user_guide/general/urls.html 
*/ 

$config['url_suffix'] = '.html'; 

EDIT:the doc

関連する問題