Location: PHPKode > projects > phpBlogger > classes/stopforumspam.php
<?php 
/**
 * checkStopForumSpam()
 * 
 * @param mixed $email
 * @return void
 */
function checkStopForumSpam($email, $ipse)
{
  libxml_use_internal_errors(true);
  @$xml_string = file_get_contents('http://www.stopforumspam.com/api?ip='.$ipse.'&email='.$email.'');
  if(!$xml_string)
  {
    echo "Failed loading document. Your host can make remote connection with the DB.";
    foreach(libxml_get_errors() as $error)
    {
    }
  } else
  {
    $xml_string = file_get_contents('http://www.stopforumspam.com/api?ip='.$ipse.'&email='.$email.'');
    $xml = new SimpleXMLElement($xml_string);
    if($xml->appears == 'yes')
    {
      echo "Sorry, your registration could not be processed.";
      $emailto = "Email: ".$email." - IP: ".$ipse."\r";
      $file = "banlog.log";
      @$fh = fopen($file,'a');
      @fwrite($fh,$emailto."\n");
      @fclose($fh);
      include ('static.php');
      die();
    }
  }
}
?>
Return current item: phpBlogger