¿Como eliminar el index.php de la instalacion de codeigniter?

Aclaracion:

Este documento esta creado como recordatorio de viejos trabajos personales y para poder ayudar a los que esten aprendiendo el lenguaje, me voy a focalizar en que sea una ayuda memoria con explicaciones basicas y minimas, no le daré suma importancia a la ortografica ni al vocabulario utilizado por ende puede haber muchos errores ortográficos y espero serle de ayuda a los que me ayudaron. (La comunidad de programadores independientes o freelance)

Solo voy aclarar una cosa que no encontre en otros sitios que me tomo mucho tiempo darme cuenta.

1 - Dejar en vacio el $config['index_page'] = ''; de application/config.php

2 - En el directorio raiz colocar el .htaccess que viene por defecto con esto:

.htaccess

AddHandler x-httpd-php5-3 .php # esta es la linea que hay que agregar para que el servidor dattatec.com funcione, sino nunca funciona el .htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /

#Removes access to the system folder by users.
#Additionally this will allow you to create a System.php controller,
#previously this would not have been possible.
#'system' can be replaced if you have renamed your system folder.
RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$ /index.php?/$1 [L]

#When your application folder isn't in the system folder
#This snippet prevents user access to the application folder
#Submitted by: Fabdrol
#Rename 'application' to your applications folder name.
RewriteCond %{REQUEST_URI} ^application.*
RewriteRule ^(.*)$ /index.php?/$1 [L]

#Checks to see if the user is attempting to access a valid file,
#such as an image or css document, if this isn't true it sends the
#request to index.php
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
</IfModule>

<IfModule !mod_rewrite.c>
# If we don't have mod_rewrite installed, all 404's
# can be sent to index.php, and everything works as normal.
# Submitted by: ElliotHaughin

ErrorDocument 404 /index.php
</IfModule>

Este es el que propone el user_guide del codeigniter 2.0.2

Removing the index.php file

By default, the index.php file will be included in your URLs:

example.com/index.php/news/article/my_article

You can easily remove this file by using a .htaccess file with some simple rules. Here is an example of such a file, using the "negative" method in which everything is redirected except the specified items:

RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

In the above example, any HTTP request other than those for index.php, images, and robots.txt is treated as a request for your index.php file.

 

Fecha de creacion: 26/06/2011
Autor: AXU Group - Desarrollo de Software - Software Factory

 

 
 
Free Web Hosting

Warning: include_once(): open_basedir restriction in effect. File(/home/a9753807/public_html/analytics.php) is not within the allowed path(s): (/home/vhosts/axu.com.ar/:/tmp/:/usr/share/pear/) in /home/vhosts/axu.com.ar/developer/codeigniter/mod_rewrite.php on line 105

Warning: include_once(/home/a9753807/public_html/analytics.php): failed to open stream: Operation not permitted in /home/vhosts/axu.com.ar/developer/codeigniter/mod_rewrite.php on line 105

Warning: include_once(): Failed opening '/home/a9753807/public_html/analytics.php' for inclusion (include_path='.:/opt/remi/php73/root/usr/share/pear:/opt/remi/php73/root/usr/share/php:/usr/share/pear:/usr/share/php') in /home/vhosts/axu.com.ar/developer/codeigniter/mod_rewrite.php on line 105