Redirect visitor using IP

I got spam on my forum. It is an old forum, and I do not have time to upgrade it. From my web statistic, the spammers seems to come from 193.53.87.95 and 193.53.87.93. I tried setting my forum, to block these IPs. But it does not seems to be working.

I’m going to try redirect the visitor from that IP to my other forum filled with spam. Here’s the code:

<?php
ob_start();
$visitor = $_SERVER['REMOTE_ADDR'];
if (preg_match("/193.53.87.95/",$visitor) 
|| preg_match("/193.53.87.93/",$visitor)) 
{
      header('Location: http://www.destination.com');
}
ob_get_clean();
?>

Related posts:

  1. How to get returning visitor
  2. Redirect using htaccess
  3. How to tackle spam in forum
  4. How to monetize a forum

3 comment(s)

  • May 16, 2009 by Robert from Internet Marketing Forum

    I have a forum but till now I haven’t problems with spam, because I have just few members. But in the future I’m convinced I will have this kind of problems, so I have bookmarked this article.

  • May 18, 2009 by admin

    Robert, Yes - the more famous your forum, the bigger chance yours 'attacked' with spams - The best way is to hire a moderator (or group of moderators).

  • May 31, 2009 by Robert from Free Internet Marketing Ebooks

    Probably in the future I will hire a moderator, but I don’t know how to find a good one. I hope I can recruit a moderator from my members, but first I must to see if there is a good one who can moderate an internet marketing related forum.

  • Any feedback from you?

    This site uses KeywordLuv. Enter YourName@YourKeywords in the Name field to take advantage.

Jul 22, 2008 by

Want to set up your own web server at home? Read this guide

Super Green Hosting HostGator GreenGeeks WP Web Host green web hosting ad