February 1st, 2006
Quick question:
Is anybody having any trouble with the images posted in this blog (the scan from the New Haven Register, or the cover of the new book, below)? We’ve disabled image hotlinking (because the Freepi keep stealing bandwidth, oddly), and it works okay on two out of the three browsers I have on my system, but on an old copy of explorer the images won’t come up, even after clearing the cache. I don’t care, if the problem is just specific to one browser on my desktop — just want to make sure no one else is having the same problem.
posted by Tom Tomorrow at 9:50 AM | link


February 1st, 2006 at 10:01 am
I’m accessing your site from my office computer using Explorer and some of the images are not coming up, just a message saying “hotlinking disabled” (oddly enough, on the comments page, the images are here.
February 1st, 2006 at 10:12 am
Thanks, I will pass this on to the webmaster.
February 1st, 2006 at 10:33 am
The images on the first page do not come up. On the next page they do.
I am running ie 6.0.2900 and going through a webproxy (Websense) and a nated address.
February 1st, 2006 at 10:33 am
was looking last night, and I got the same message that Ellen got last night - it was very strange - I have XP and was viewing it using IE —- but, I check your site all the time at home and this was the first time I had trouble with it -
February 1st, 2006 at 10:49 am
My web guy usually gets back to work in the early afternoon, it’ll probably be straightened out then. In the meantime, this site apologizes for any inconvenience.
February 1st, 2006 at 11:18 am
IE verison 6.0.2 is showing the graphics on the 2nd level pages, but the don’t hot link warning on the first page.
Weird
February 1st, 2006 at 12:28 pm
Ditto on what Ellen said.
February 1st, 2006 at 12:47 pm
Works fine on my work IE and home Firefox with no probs.
February 1st, 2006 at 1:30 pm
No problems at all with firefox.
February 1st, 2006 at 1:56 pm
A wild guess: Whoever set up the image blocking is doing it based on the Referer entry the web browser sends. The filter is something like, “If the referer is a page from thismodernworld.com, send the image. Otherwise, send the ‘NO LINKING’ image”. While that _usually_ works, there is one common case where it fails: if the Referer entry is missing or blank. I’m not entirely sure why this happens, I’m guess that web proxies are sometimes to blame. Of course, some browser and privacy-filters will quietly delete the Referer. Anyway, the solution is to allow a blank or missing Referer to access your images. This does mean that if someone posts your images on their pages, a small number of their visitors will see your images and not the “NO LINKING” image. Still, the majority of the bad sites visitors will get the NO LINKING warning, which is probably Good Enough.
February 1st, 2006 at 2:09 pm
While that _usually_ works, there is one common case where it fails: if the Referer entry is missing or blank
Thanks! Below is the relevant snippet of code. I thought that the first line in my code below accounts for the no-referrer calls, I wonder why it’s not working across all browsers? One would think the kind of browser used has no effect on the referrer data.
RewriteCond %{HTTP_REFERER} !^$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*)thismodernworld(.*)$ [NC]
RewriteCond %{HTTP_REFERER} !^http://(.*)huffington(.*)/.*$ [NC]
RewriteRule \.(gif|jpg)$ http://winterswebworks.com/images/hotlink.gif [R,L]
I’ve turned off the hotlink-protection pending a better solution.
-Jonah, webmaster
February 1st, 2006 at 4:48 pm
I’m not sure if this is causing the problem or not, but there are a few problems with your rules:
By having the ‘.*’ in there at the front right after the ‘http://’ I could link to you like:
http://somenastysiteyouhate.com/thismodernworldsucks/foo.html
And you’d serve the content.
You don’t need the [NC] after your first rule, an empty string doesn’t need to be case insensitive.
Unless you’re actually using the backreferences, you shouldn’t use the parentheses around the “.*” in your regular expressions, it just slows it down. When you’re using ! to negate the patterns, I think it’s actually invalid, i.e. how can you have a stored backreference to a string that doesn’t match? That might break the rule right there.
Also, you need the ‘NC’ on your RewriteRule too, not just the RewriteCond-itions, unless you only have images named in lowercase.
You could turn rewriting back on, and try logging the stuff to see
what’s happening. Not sure what version you’re using, but this should work to do that:
RewriteLog “/var/log/apache/rewrite”
RewriteLogLevel 5
Don’t leave that on for long though, it’ll make a *big* log.
Feel free to e-mail me at sean at subrew dot com if you want to talk about this more…
February 1st, 2006 at 7:04 pm
Feel free to e-mail me
Thanks, Sean and Alan! I’ll look into this more in a couple days and ask you for advice if I get stuck. I’ve never had to use hotlink protection for my other sites — but all the other domains on my server get only 50% of the traffic and 1% of the vitriol that ThisModernWorld generates. :-)
-Jonah
February 2nd, 2006 at 8:21 pm
They seem to be working here.
Dell Inspiron 6000, Celeron, Slackware v. 10.2, 512 MB RAM, Opera 8.51. F-Prot Antivirus, Projectfiles Firewall, KDE 3.4