<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</IfModule>
步驟如上。這時輸入網址,應該可以將原本的domain.com/index.php去掉,只要domain.com/ 就可以執行index.php了。
AWS、PHP、LINUX、APACHE、MYSQL、CAKEPHP、JAVASCRIPT…….
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</IfModule>
步驟如上。這時輸入網址,應該可以將原本的domain.com/index.php去掉,只要domain.com/ 就可以執行index.php了。