Robots.txt Tip + Webinale.de

Purdy on 2008-03-28T21:00:16

Knocking off some of the dust here... wanted to share two quickies:

I finally figured this out, and it may be beneath you, but let's say you have a web document root that's shared between ports 80 and 443 (iow, http and https go to the same place). Then your site gets spidered by the search engines and they put a bunch of your stuff in a supplemental index because it's redundant. Since there's only one robots.txt file, you can't easily say IF https, then go away w/o saying the same thing to the http version. So what do you do? Create a robots-ssl.txt file and then in your ssl apache configuration, use Alias:

Alias /robots.txt /path/to/robots-ssl.txt

Then http://www.example.com/robots.txt and https://www.example.com/robots.txt have two different contents, while sharing the same web root directory!

You probably already knew this, didn't you?

Ok, next up ... in more exciting news, I'm speaking at webinale.de! I submitted 6 talks, 5 technical and 1 marketing ... and wouldn't you know it? The marketing talk is approved. So I'll be speaking on SEO. I've been listening & learning German via the Deutche Welle podcasts and I'm lurking on #perlde to pick up reading & writing German, too. Thankfully, I'll be able to do my presentation in English (I think it would be torture to listen to my German ;)).

Peace,

Jason

PS: How ironic (ok, English nerds, coincidental ;)) is it that I'm listening to Daft Punk atm?


thanks

markjugg on 2008-03-29T23:26:27

The robots.txt example was useful. Thanks!

      Mark