Ver Mensaje Individual
  #1 (permalink)  
Antiguo 10/12/2015, 13:34
fearhds
 
Fecha de Ingreso: noviembre-2007
Mensajes: 97
Antigüedad: 16 años, 5 meses
Puntos: 0
modificar htaccess para poder ver subdominio

Hola,

Estoy intentando crear un subdominio en un dominio que tiene CodeIgniter, y tengo problemas con el htaccess ya que no entiendo mucho como funciona.

Necesito que si entro a

XXXX.midominio.com/index.php me redirija a www.midominio.com/cliente/XXXX

y el htaccess me lo bloquea y no se como ponerlo , os pego mi código actual

Código:
<IfModule mod_rewrite.c>

    RewriteEngine On
    RewriteBase /
 
    RewriteCond %{REQUEST_URI} ^application.*
    RewriteRule ^(.*)$ index.php?/$1 [L]
 
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php?/$1 [L]

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



</IfModule>

<IfModule !mod_rewrite.c>

    ErrorDocument 404 index.php

</IfModule>

muchas gracias por la ayuda

Última edición por fearhds; 10/12/2015 a las 13:48