\n"; include "form.inc"; echo "\n"; include "footer.inc"; } else{ if($Censor==1){ $blurb = "@!#$"; $sSQL = "Select word from profan"; mysql_select_db( $sDB); $nProfan = mysql_query( $sSQL ); if ( $nProfan > 0 ){ $nRows = mysql_num_rows ( $nProfan ); if ( $nRows > 0 ){ $a=0; While($a<$nRows){ $sWord = mysql_result ( $nProfan, $a, "word" ); $name = eregi_replace( $sWord, $blurb, $name ); $topic = eregi_replace( $sWord, $blurb, $topic ); $email = eregi_replace( $sWord, $blurb, $email ); $body = eregi_replace( $sWord, $blurb, $body ); $a++; } } } } if($UseCookies==1){ if((!IsSet($$cNameVar)) || ($$cNameVar != $name)) { SetCookie("$cNameVar",$name,time()+ 31536000); } if((!IsSet($$cEmailVar)) || ($$cEmailVar != $email)) { SetCookie("$cEmailVar",$email,time()+ 31536000); } } if(!eregi(".+@.+\\..+", $email) && $email!=$ModPass){ $email=""; } if($MagicQuotes!=1){ $name = addslashes($name); $email = addslashes($email); $topic = addslashes($topic); $body = addslashes($body); } $date = date("Y-m-d H:i:s"); $host = getenv('REMOTE_HOST'); $host = @GetHostByAddr($host); $stripHTML = TRUE; if($AllowHTML==1){ $stripHTML=FALSE; } if($UseModerator==1 && $email==$ModPass){ $stripHTML=FALSE; } $name = htmlspecialchars($name); $email = htmlspecialchars($email); $topic = htmlspecialchars($topic); if($stripHTML){ $body = htmlspecialchars($body); } else{ $body=eregi_replace("<\\?", "<?", $body); $body=eregi_replace("\\?>", "?>", $body); $body=eregi_replace("", "</script>", $body); } if($EmailModerator==1){ mail($Moderator, stripslashes($topic), stripslashes($body), "From: Phorum <$Moderator>"); } if($UseModerator==1 && $email==$ModPass){ $email=$Moderator; $name = "$name"; $topic = "$topic"; } $sSQL = "Insert Into $sTable (name, email, datestamp, topic, body, host, thread) values ('$name', '$email', '$date', '$topic', '$body', '$host', $thread)"; mysql_select_db($sDB); $nResult = mysql_query($sSQL); //$nResult = mysql_db_query ( $sDB, $sSQL, $nConnection ); $sUSQL = "Update $sTable set thread=id where thread = 0"; $nUResult = mysql_query($sUSQL); if($nResult==0){ echo "$nResult - $sSQL"; } else{ $more=""; if($thread!=0){ $more = $thread+1; $more = "?more=".$more; } Header ("Location: index.html$more"); } } ?>