Welcome to WebmasterWorld Guest from 107.20.75.63

Forum Moderators: Ocean10000 & incrediBILL & phranque

Message Too Old, No Replies

Combining RewriteConds

     
12:19 am on Sep 29, 2003 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member keyplyr is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Sept 26, 2001
posts:5805
votes: 64


Can these two strings..

RewriteCond %{HTTP_REFERER}!^http://babel\.altavista\.com/.*www\.mydomain\.net
RewriteCond %{HTTP_REFERER}!^http://babelfish\.altavista.com/.*www\.mydomain\.net

...be combined into this?

RewriteCond %{HTTP_REFERER}!^http://babel.\.altavista\.com/.*www\.mydomain\.net

...or should it be writtenthis way?

RewriteCond %{HTTP_REFERER}!^http://babel(fish)\.altavista\.com/.*www\.mydomain\.net

Thanks

12:24 am on Sept 29, 2003 (gmt 0)

Senior Member

WebmasterWorld Senior Member jdmorgan is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Mar 31, 2002
posts:25430
votes: 0


keyplyr,

RewriteCond %{HTTP_REFERER} !^http://babel(fish)?\.altavista\.com/.*www\.mydomain\.net

The "?" makes the preceding character or group (bounded by parentheses) optional.

Ref: [etext.lib.virginia.edu...]

Jim

12:31 am on Sept 29, 2003 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member keyplyr is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Sept 26, 2001
posts:5805
votes: 64



Terrific, thanks Jim.

While we're on the subject (he he) have you ever seen AV's translator referral written as "babel"? Because all the referrers I see are "babelfish"

So unless both really do exist, I might just go with the second one anyway.

Thanks.

<added> works fine, might as well not try to fix it anymore ;)