Rewrite help (might be similar to old requests)

Discuss practical ways rearrange URLs using mod_rewrite.

Rewrite help (might be similar to old requests)

Postby NcF » Sun May 15, 2005 8:48 pm

:confused:

Ok, so here's my little issue that I've been pulling my hair out for a while now with. I'm relatively new to mod_rewrite, but have done a lot with PHP's ereg and PCRE.

I'm trying to map one directory out in the server, using various things, each of which have failed. So for ease of understanding, I have gathered about 4 examples of REQUEST_URIs that I am trying to map out, and their resultant.

/vane/
=> /vane/index.php?mod=news&submod=main
/vane/photo/
/vane/photo
=> /vane/index.php?mod=photo&submod=main
/vane/news/archive/
/vane/news/archive
=> /vane/index.php?mod=news&submod=archive
/vane/news/comments/id/9/hash/b00b09ccc21a311b3895d0d696390986
=> /vane/index.php?mod=news&submod=comments&id=9&hash=b00b09ccc21a311b3895d0d696390986

Noteably, there may be many parameters in the URL which may need to be rewritten.

Would it just be easier to rewrite this using PHP? :\

-Wes
NcF
 

Return to Friendly URLs with Mod_Rewrite

Who is online

Users browsing this forum: No registered users and 23 guests

cron