wamp中的index.php,codeigniter – 如何删除Wamp中的index.php?
生活随笔
收集整理的這篇文章主要介紹了
wamp中的index.php,codeigniter – 如何删除Wamp中的index.php?
小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
請(qǐng)嘗試以下方法:
1)與應(yīng)用程序文件夾并行創(chuàng)建.htaccess文件,只需復(fù)制粘貼以下代碼:
RewriteEngine On
RewriteBase /CodeIgniter/
RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$/index.php/$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$index.php/$1 [L]
2)將$config [‘index_page’]更改為應(yīng)用程序文件夾中config.php中的空白,如下所示:
$config['index_page'] = '';
3)啟用apache的“rewrite_module”.點(diǎn)擊WAMP符號(hào) – > Apache – > Apache模塊 – > rewrite_module
現(xiàn)在,您可以在url中訪問(wèn)沒(méi)有index.php的站點(diǎn).
總結(jié)
以上是生活随笔為你收集整理的wamp中的index.php,codeigniter – 如何删除Wamp中的index.php?的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: 牙磨小了戴牙套好不好
- 下一篇: 金属牙套和烤瓷牙套的区别