Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Conditionnal mod_rewrite - How to ?

 
Franck Tranchant
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I'm very new at mod_rewriting and i wonder how i could set up this kind of logic :

if (url.contains("aaa")){
redirect http://www.my_first_domain.com
exit
}
if (url.contains("bbb")){
redirect to http://www.my_second_domain.com
exit
}

Could someone give me the first steps ?
 
Franck Tranchant
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just in case someone is interested, I find a simple way to do that using only RedirectMatch. Actually, RewriteCond + RewriteRule were not necessary.

Instructions below work fine :


So simple..

[ October 04, 2006: Message edited by: Franck Tranchant ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic