Foros del Web » Programando para Internet » PHP » CodeIgniter »

Problema con url y caracteres.

Estas en el tema de Problema con url y caracteres. en el foro de CodeIgniter en Foros del Web. Hola estoy utilizando codeigniter pero me tira un error en esta url http://www.dominiio.com/?install=1&e...scrtion=the+us este es el error An Error Was Encountered The URI you submitted ...
  #1 (permalink)  
Antiguo 30/06/2011, 10:25
Avatar de RIVERMILLOS  
Fecha de Ingreso: marzo-2010
Mensajes: 1.336
Antigüedad: 14 años, 2 meses
Puntos: 15
Problema con url y caracteres.

Hola estoy utilizando codeigniter pero me tira un error en esta url


http://www.dominiio.com/?install=1&e...scrtion=the+us


este es el error

An Error Was Encountered

The URI you submitted has disallowed characters.


esta es al configuracion que tengo para los caracteres.

$config['permitted_uri_chars'] = 'a-z 0-9~%\.\:_\-+';



saludos
  #2 (permalink)  
Antiguo 30/06/2011, 10:36
Avatar de RIVERMILLOS  
Fecha de Ingreso: marzo-2010
Mensajes: 1.336
Antigüedad: 14 años, 2 meses
Puntos: 15
Respuesta: Problema con url y caracteres.

Ya lo puedo solucionar con esta configuracion

$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-?=&+';

pero ahora el problema con la misma url

404 Page Not Found

The page you requested was not found.


que puede ser?


saludos
  #3 (permalink)  
Antiguo 30/06/2011, 11:42
Avatar de NUCKLEAR
Moderador radioactivo
 
Fecha de Ingreso: octubre-2005
Ubicación: Cordoba-Argentina
Mensajes: 5.688
Antigüedad: 18 años, 6 meses
Puntos: 890
Respuesta: Problema con url y caracteres.

Podrias escapar los caracteres:
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-\?\=\&\+';

Si aun asi te sigue dando 404 debes revisar el codigo.

Saludos.
__________________
Drupal Argentina
  #4 (permalink)  
Antiguo 30/06/2011, 16:16
Avatar de RIVERMILLOS  
Fecha de Ingreso: marzo-2010
Mensajes: 1.336
Antigüedad: 14 años, 2 meses
Puntos: 15
Respuesta: Problema con url y caracteres.

hola gracias si me funciono lo de los caracteres pero el problema es que ahora me dice

The page you requested was not found.


esta es la url http://www.dominiio.com/?install=1&e...scrtion=the+us

no se si es porque el htacces que tengo para quitar el index.


saludos
  #5 (permalink)  
Antiguo 30/06/2011, 16:54
Avatar de NUCKLEAR
Moderador radioactivo
 
Fecha de Ingreso: octubre-2005
Ubicación: Cordoba-Argentina
Mensajes: 5.688
Antigüedad: 18 años, 6 meses
Puntos: 890
Respuesta: Problema con url y caracteres.

Pon tu htaccess y podrias probar esta parte de la configuracion :

Código PHP:
Ver original
  1. /*
  2. |--------------------------------------------------------------------------
  3. | URI PROTOCOL
  4. |--------------------------------------------------------------------------
  5. |
  6. | This item determines which server global should be used to retrieve the
  7. | URI string.  The default setting of "AUTO" works for most servers.
  8. | If your links do not seem to work, try one of the other delicious flavors:
  9. |
  10. | 'AUTO'            Default - auto detects
  11. | 'PATH_INFO'       Uses the PATH_INFO
  12. | 'QUERY_STRING'    Uses the QUERY_STRING
  13. | 'REQUEST_URI'     Uses the REQUEST_URI
  14. | 'ORIG_PATH_INFO'  Uses the ORIG_PATH_INFO
  15. |
  16. */
  17. //$config['uri_protocol']   = "PATH_INFO";
  18. $config['uri_protocol'] = "REQUEST_URI";
  19. //$config['uri_protocol']   = "AUTO";

Prueba con cual te puede ir bien.

Saludos.
__________________
Drupal Argentina
  #6 (permalink)  
Antiguo 01/07/2011, 08:47
Avatar de RIVERMILLOS  
Fecha de Ingreso: marzo-2010
Mensajes: 1.336
Antigüedad: 14 años, 2 meses
Puntos: 15
Respuesta: Problema con url y caracteres.

Este es el htacces.


Código Apache:
Ver original
  1. Options All -Indexes +FollowSymLinks
  2. RewriteEngine on
  3. RewriteCond %{HTTP_HOST} ^xxxxx.com.co [NC]
  4. RewriteRule ^(.*)$ http://www.xxxxx.com.co/$1 [L,R=301]
  5. ErrorDocument 404 http://www.xxxxxx.com.co/error
  6. ErrorDocument 403 http://www.xxxxxxx.com.co/error
  7.  
  8. <IfModule mod_rewrite.c>
  9. RewriteEngine On
  10. RewriteBase /
  11. RewriteCond %{REQUEST_FILENAME} !-f
  12. RewriteCond %{REQUEST_FILENAME} !-d
  13. RewriteRule ^(.*)$ index.php/$1 [L]
  14. </IfModule>

lo coloque en REQUEST_URI y si funca pero tu me podrias explicar estas configuraciones , porque no entiendo como funcionan he buscado en la web y creo que no hay una explicacion o un tuto sobre esto.

Código PHP:
Ver original
  1. //$config['uri_protocol']   = "PATH_INFO";
  2. $config['uri_protocol'] = "REQUEST_URI";
  3. //$config['uri_protocol']   = "AUTO";
  #7 (permalink)  
Antiguo 27/07/2011, 08:34
Avatar de cemansilla  
Fecha de Ingreso: septiembre-2007
Ubicación: Buenos Aires, Argentina, Argentina
Mensajes: 214
Antigüedad: 16 años, 7 meses
Puntos: 6
Respuesta: Problema con url y caracteres.

Me pasó varias veces, aquí la solución que uso: http://oskoi.com/2011/07/error-the-u...n-codeigniter/

Etiquetas: caracteres, frameworks-y-php-orientado-a-objetos, url
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 23:58.