views:

24

answers:

1

Original Question:

what could be the mod_rewrite, to rewrite urls with this structure: http://hiwis.net/jobs/Computer/ to something with this structure: http://hiwis.net/Computer/

--

I need some help with the mod_rewrite for my hiwis(dot)net site to rewrite urls with this structure: hiwis(dot)net/jobs/Computer/ to something with this structure: hiwis(dot)net/Computer/ , thanks

A: 
RewriteRule ^/?jobs/Computer/(.*)$ /Computer/$1 [R]
Ignacio Vazquez-Abrams
why '?' before jobs ?
shikhar
So that it will work whether it's in a server config file or in a `.htaccess` file.
Ignacio Vazquez-Abrams
Thanks Ignacio for the help but, it seems like I'm missing something? it seems to not work at my end. Maybe I should make it clearer my ulr stucture is www.domain.net/something/keyword and I'd like it to be www.domain.net/keyword
Are you saying that the word in the beginning could be something other than "jobs"?
Ignacio Vazquez-Abrams
no, it's always Jobs, but I've tried the code, and it doesn't seems to work, and it keeps displaying the same way. Thanks for any further help.
Wait... is it "jobs" or "Jobs"? Patterns are case sensitive, unless you use the `NC` flag.
Ignacio Vazquez-Abrams