Ver Mensaje Individual
  #33 (permalink)  
Antiguo 20/10/2009, 15:48
kadas99
 
Fecha de Ingreso: julio-2009
Ubicación: Argentina!
Mensajes: 324
Antigüedad: 15 años, 7 meses
Puntos: 4
Respuesta: Urls Amigables sin Mod_Rewrite ni Httacces

Bueno despues de volver todo a cero varias veces y volver a empezar para tratar de no arrastrar algun error, sigo sin que funcione, ya esto es una frustracion muy grande.

Ahora encontre un supuesto "Tutorial" para activar el mod_rewrite en apache, en el cual dice claramente que debemos hacer esto:

1) Buscar LoadModule rewrite_module modules/mod_rewrite.so y descomentarlo (Osea, sacarle el '#')

Hasta aca todo bien!

2) Buscar ClearModuleList y descomentarla (Esta no esta por ningun lado, asi que opte por agregarla al principio).
3) Buscar AddModule mod_rewrite.c y descomentarla (Esta tampoco esta, tambien la agregue).

Despues dice que debemos chekear si esta funcionando o no el mod_rewrite, para lo cual hay que crear un .htaccess (Ya lo odio al .htaccess) y ponerle estas lineas para ver si funciona.

4) Options +FollowSymLinks
RewriteEngine On


listo, hice eso, salve todo, reinicie la pc y... Hooo! lo que me esperaba, no anda!, pero... en el tuto dice que hay 2 opciones, que funcione y que no funcione, siempre me toca la peor, pero bueno, en el caso de que no funcione, te dice que te puede tirar un error 505, pero he aqui otro problema, a mi me tira error 404 (porque no puedo ser como el comun de la gente??)

Resumiendo todo:

1) No tengo las lineas ClearModuleList ni AddModule mod_rewrite.c.
2) En lugar de darme el error 404 me da error 505.

¿Que puede ser? ¿Que hago? ¿format c:\ y me dedico a pedir monedas en la calle?

Una cosita mas, me fije en el Error Log de Apache y voy a copypastear lo ultimo:

Cita:
[Tue Oct 20 16:39:03 2009] [notice] Apache/2.2.8 (Win32) PHP/5.2.6 configured -- resuming normal operations
[Tue Oct 20 16:39:03 2009] [notice] Server built: Jan 18 2008 00:37:19
[Tue Oct 20 16:39:03 2009] [notice] Parent: Created child process 1660
[Tue Oct 20 16:39:03 2009] [warn] module rewrite_module is already loaded, skipping
[Tue Oct 20 16:39:03 2009] [warn] module rewrite_module is already loaded, skipping
PHP Warning: PHP Startup: Unable to load dynamic library 'C:/AppServ\\php5\\ext\\php_exif.dll' - No se puede encontrar el m\xf3dulo especificado.\r\n in Unknown on line 0
PHP Warning: Module 'mysql' already loaded in Unknown on line 0
[Tue Oct 20 16:39:04 2009] [notice] Child 1660: Child process is running
[Tue Oct 20 16:39:04 2009] [notice] Child 1660: Acquired the start mutex.
[Tue Oct 20 16:39:04 2009] [notice] Child 1660: Starting 64 worker threads.
[Tue Oct 20 16:39:04 2009] [notice] Child 1660: Starting thread to listen on port 80.
[Tue Oct 20 18:24:18 2009] [warn] module rewrite_module is already loaded, skipping
[Tue Oct 20 18:24:18 2009] [warn] module rewrite_module is already loaded, skipping
[Tue Oct 20 18:24:18 2009] [warn] pid file C:/AppServ/Apache2.2/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
PHP Warning: PHP Startup: Unable to load dynamic library 'C:/AppServ\\php5\\ext\\php_exif.dll' - No se puede encontrar el m\xf3dulo especificado.\r\n in Unknown on line 0
PHP Warning: Module 'mysql' already loaded in Unknown on line 0
[Tue Oct 20 18:24:19 2009] [notice] Apache/2.2.8 (Win32) PHP/5.2.6 configured -- resuming normal operations
[Tue Oct 20 18:24:19 2009] [notice] Server built: Jan 18 2008 00:37:19
[Tue Oct 20 18:24:19 2009] [notice] Parent: Created child process 1996
[Tue Oct 20 18:24:19 2009] [warn] module rewrite_module is already loaded, skipping
[Tue Oct 20 18:24:19 2009] [warn] module rewrite_module is already loaded, skipping
[Tue Oct 20 18:24:19 2009] [warn] module rewrite_module is already loaded, skipping
[Tue Oct 20 18:24:19 2009] [warn] module rewrite_module is already loaded, skipping
PHP Warning: PHP Startup: Unable to load dynamic library 'C:/AppServ\\php5\\ext\\php_exif.dll' - No se puede encontrar el m\xf3dulo especificado.\r\n in Unknown on line 0
PHP Warning: Module 'mysql' already loaded in Unknown on line 0
[Tue Oct 20 18:24:20 2009] [notice] Child 1996: Child process is running
[Tue Oct 20 18:24:20 2009] [notice] Child 1996: Acquired the start mutex.
[Tue Oct 20 18:24:20 2009] [notice] Child 1996: Starting 64 worker threads.
[Tue Oct 20 18:24:20 2009] [notice] Child 1996: Starting thread to listen on port 80.
[Tue Oct 20 18:25:30 2009] [error] [client 127.0.0.1] File does not exist: C:/AppServ/www/ventafacil/1.html, referer: http://localhost/ventafacil/index.php
[Tue Oct 20 18:26:40 2009] [error] [client 127.0.0.1] File does not exist: C:/AppServ/www/ventafacil/1.html, referer: http://localhost/ventafacil/index.php
[Tue Oct 20 18:27:07 2009] [error] [client 127.0.0.1] File does not exist: C:/AppServ/www/ventafacil/1.html, referer: http://localhost/ventafacil/index.php
[Tue Oct 20 18:27:12 2009] [error] [client 127.0.0.1] File does not exist: C:/AppServ/www/ventafacil/1.html, referer: http://localhost/ventafacil/index.php
por lo que veo y entiendo, esto: [Tue Oct 20 18:24:19 2009] [warn] module rewrite_module is already loaded, skipping significa que el mod anda
y aca creo que estoy errando feo: [Tue Oct 20 18:27:07 2009] [error] [client 127.0.0.1] File does not exist: C:/AppServ/www/ventafacil/1.html, referer: http://localhost/ventafacil/index.php
[Tue Oct 20 18:27:12 2009] [error] [client 127.0.0.1] File does not exist: C:/AppServ/www/ventafacil/1.html, referer: http://localhost/ventafacil
.

estas son las reglas que tengo para probar en el .httacces:

RewriteEngine On
RewriteRule ^ventafacil/(.+)\.htm$ ventafacil/muestraproducto.php?idproducto=$1


o

RewriteEngine On
RewriteRule ^ventafacil/([^/]*)\.html$ /ventafacil/muestraproducto.php?idproducto=$1 [L]

Última edición por kadas99; 20/10/2009 a las 15:58 Razón: Agregue informacion