title: GeoIP on shared hosting
body: <p>Some of the website's I've made are having problems with spammers. I've made sure that messages have to be approved before they are published, but lately it's been getting a lot worse.</p>
  
  <p>There's only one link I can see between all the spam messages. All of the IP addresses are, according to <code>geoiplookup</code>, from China (and a few from Ukraine). I thought "Well, that's easy. Just block those 2 countries. It's a Dutch website anyway.". The problem is that the <a href="http://php.net/manual/en/book.geoip.php" rel="nofollow">GeoIP</a> extension isn't installed on the shared hosting in question.</p>
  
  <p>I'd prefer this solution over things like Captcha (nobody can read those bloody things anyway) or the need to register and login.
  I'd also prefer not to depend on other websites, as they can go offline, or steal information. </p>
  
  <p>Is there some other way to do it? The country is the only link I've been able to find. User agents same to be random, so do the IP addresses appart from all belonging to the same 2 countries. I've already implemented something that blocks users from posting over the Tor network, but they don't appear to be using Tor.</p>
  
  <p>I know I can get somebody's location with Javascript, but that's client side and can easily be disabled.</p>