Jump to content


Kymmmmmm

Member Since 28/04/2008
Offline Last Active 06/05/2008, 16:49
-----

Topics I've Started

Url Amigável !

29/04/2008, 10:15

Galera to tentando implementar as tais urls amigaveis, mas ta complicado viu, não sei porque não funciona heh..

To tentando fazer localmente antes de upar pro host, aqui vai minhas configurações locais:

PHP Version 5.1.2
Apache HTTP Server 2.0.55


De acordo com o phpinfo(), tenho esses modulos carregados:

Loaded Modules core mod_win32 mpm_winnt http_core mod_so mod_access mod_actions mod_alias mod_asis mod_auth mod_autoindex mod_cgi mod_dir mod_env mod_imap mod_include mod_isapi mod_log_config mod_mime mod_negotiation mod_rewrite mod_setenvif mod_php5 mod_userdir


Então, criei o arquivo .htaccess no diretorio .../Apache2/htdocs com a seguinte estrutura:

RewriteEngine on
RewriteBase /~gamesphere/
RewriteRule ^(.+)\/?([0-9]*)\/?$ /index.php?page=$1&id=$2


Então eu tenho essa URL: http://localhost/gamesphere/?page=exibe_news&id=3
Estou tentando acessar através de: http://localhost/gamesphere/exibe_news/3

E simplesmente não funciona :(

Not Found

The requested URL /gamesphere/exibe_news/3 was not found on this server.
Apache/2.0.55 (Win32) PHP/5.1.2 Server at localhost Port 80


Segui este tutotial http://brunotorres.net/urls e tentei sem essa linha "RewriteBase /~gamesphere/" e sem o "~", todos dando o mesmo erro.

Alguém saberia me ajudar? Pretendo usar esse recurso num site de games que eu faço (www.gamesphere.com.br) e tornar url's como essa http://www.gamespher.../...=19&idp=122 mais amigaveis heh

Grato pela atenção

IPB Skin By Virteq