3 ms·
Very cute. :-) Now that we've all had a laugh, wouldn't it make more sense to have the server respond with a redirect to a shared copy of the script hosted som
by jt2190 13y ago
Very cute. :-)
Now that we've all had a laugh, wouldn't it make more sense to have the server respond with a redirect to a shared copy of the script hosted somewhere that provides bandwidth for free? (Perhaps this is a sign that the script should be open-sourced as well.)
- tibbon 13y agoBut bandwidth isn't free. Someone's gotta pay for it in some way or another, and if a major company lets say is using your hosted copy without asking, then perhaps they should host their own?
- ithkuil 13y agothere are cdns happy to host useful opensource scripts for free, assuming you want to release your script as open source.
- arcatek 13y agoThis script is used by rawgithub.io. It allows to punish the 'abusers'. There isn't really a notion of open-source in it. I think the idea is more that if someone is eating your bandwidth by hotlinking your jQuery.js, then you can serve them this instead.
- orthecreedence 13y agoIf someone hotlinked one of my scripts, I'd update the head of the script and use the opportunity for free marketing: if(!window.location.host.match(/(www\.)?myapp.com/)) window.location = 'http://www.myapp.com'; I bet they won't hotlink after that.
- jt2190 13y agoI like this. I'd think it'd be even better if instead of getting them to stop linking, you could turn them into a permanent source of referrals.
- orthecreedence 13y agoIf you added a `Math.random() < .01` in the if clause, I doubt they'd ever even notice, and depending on how much traffic they get you could have a nice steady flow of referrals =].
- danielweber 13y agoI know someone who had, of all people, Facebook hot-linking to his stuff. He redirected all visitors to his homepage. Then Facebook's legal department called his home number, his wife answered and got nervous, and it all ended there.
- orthecreedence 13y agoInteresting! I personally would have loved to have a chat with Facebook's legal team about the issue. Although I'm a bit surprised they'd actually call him instead of either a) not hotlinking anymore (seems to be the most obvious solution) or b) just sending a quick C&D. I'd be surprised if they actually have a leg to stand on legally if they are hotlinking off someone's site, especially if there's have no prior agreement to allow them to do so.
- foobarian 13y agoSounds fishy. It would take days for any kind of legal action like this. Doesn't FB push code like every couple of hours? A code patch would have been many times quicker.