Location: PHPKode > scripts > Net Shoubox > net-shoubox/words_banned.php
<?php
session_start();
//////
//
// Net Shout
//
// www.php-net.net/
//
/////
if (session_is_registered("nettag")){
// all ips banned
require_once "net_config.php";
echo $_links_admin;
if ($_GET['action']=="add_word"){
if(isset($_POST['shout'])){
mysql_query("INSERT INTO net_filter(find,replacewith) VALUES('$_POST[find]','$_POST[replacewith]')");
echo <<<EOT
<script type="text/javascript">
//<![CDATA[
alert('Filter added to word filter list')
//]]>
</script>
EOT;
}
echo <<<EOT
<td colspan="3" align="center"><b>Add Filter:</b><br />
<br />
<form method="post" action="">Find: <input type="text" name="find" class="input" size="10" /> Replace With: <input type="text" name="replacewith" size="10" /><input name="shout" type="submit" id="shout" value="Shout!" /></form></td>
EOT;
}
if ($_GET['action']=="delete_word"){
$sql=mysql_query("DELETE FROM net_filter WHERE id ='$_GET[aid]'");
echo "THE WORD ARE REMOVED FROM LANGUAGE FILTER<br />";
}
$showwords = mysql_query("SELECT * FROM net_filter ORDER BY id DESC");
if(mysql_num_rows($showwords) == '0'){
$message = "No have Words in your language filter<br />";
echo $message ;
}
echo"<a href='?action=add_word'>Add Word</a><br>";
while($rowords = mysql_fetch_array($showwords)){
echo("<tr bgcolor=\"000000\">\n");
echo "<td>Bad Word :<b>".$rowords['find']."</b> Replace for : ".$rowords['replacewith']."<a href='?action=delete_word&aid=$rowords[id]'>delete</a><br />
</td>";
echo "</tr>";
}
} else {
echo <<<EOT
<html>
<head>
<title></title>
</head>
<body>
<br /><p align="center">
ACCESS DENIED!!!!!!!!!!!<br />
<a href="login.php"><b>-- LOGIN HERE --</b></a></p>
<br />
</body>
</html>
<!-- //DO NOT REMOVE!!! -->
<span style="font-size:8pt;"><a href="http://php-net.net/">empowered by Net shout .5</a></span>
<!-- //END OF DO NOT REMOVE!!! -->
EOT;
exit;
}
?>
Return current item: Net Shoubox