View Single Post
Old 04-26-2010, 03:27 PM  
V_RocKs
Damn Right I Kiss Ass!
 
Industry Role:
Join Date: Dec 2003
Location: Cowtown, USA
Posts: 32,422
.htaccess mod_rewrite problem

I would like to set up a site where this happens:

http://www.domain.com/ => loads index normally
http://www.domain.com/this-subdirectory/ => index.php?id=this-subdirectory
http://www.domain.com/anothersub/ => index.php?id=anothersub
http://www.domain.com/whatever/you/put => index.php?=whatever/you/put

I tried various ways of doing it and either ended up in a loop or it didn't work at all. If I used something like /this_never_changes/(+.) I could easily pass the variable, but I need the variable to be the subdirectories themselves.
V_RocKs is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote