Hacker News new | ask | show | jobs
by jpoesen 1430 days ago
Fun idea.

If the site is not a static one, you could check the request's User Agent server-side, and return the raw version directly (or redirect to /foo/raw) if the UA contains 'curl' or 'wget'.

If the site is static and you are able & willing to change your vhost config, you could detect the UA too, and redirect to /foo/raw.

Just a few ideas. This is a fun little project you've got here. Well done.