I know this question has been asked one thousand time. But I have problem applying it to my project however.
What I do: I have copied the following code (suggested by CI Docs) in .htaccess file in my application folder:
RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]
PROBLEM: it does not work and it throws 404 or Internal Error. I also have tries creating new .htaccess file in my root folder, or copying the above code in system folder's .ht . none of them works. 404 or internal error are inervitable