Forum Moderators: phranque

Message Too Old, No Replies

         

carfac

5:32 pm on Sep 17, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi:

I am working on a modification for Apache::BlockAgent, and I cant seem to get it right. What I want to do is- even though it is set to block a specific agent- let it return robots.txt ok...

I have tried many different variations on this theme:

return OK if $r->uri = "/robots.txt";

Since I can't get it to work, I thought I would ask the experts!

Thanks!

Dave

andreasfriedrich

5:40 pm on Sep 17, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



prima facie: have you tried
return OK if $r->uri eq "/robots.txt";

carfac

5:48 pm on Sep 17, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Andreas:

DUH! (Slaps himself upside his head) I can be such an idiot sometimes!

Thank you- you have been a tremendous help!

dave

carfac

5:57 pm on Sep 17, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi:

Just checking back in after testing- yes, it works beautiifully!

I just gotta keep those = and eq straight!

dave

andreasfriedrich

6:10 pm on Sep 17, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi Dave,

keep this is mind:

== tests for for numeric equality
eq tests for string equality
= asignment operator

Andreas