Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - kluby

Pages: [1]
1
Applications / Re: Bad Word Filter with PHP
« on: October 09, 2009, 01:45:41 AM »
Code: [Select]
<?php 
$text 
$_POST['text'];
$text2 $_POST['text2'];
$text3 $_POST['text3'];
if(isset(
$_POST['submit']))
{
$name=array($text,$text2,$text3);
foreach (
$name as $name
{
if (
ereg("^\.",$name)) {
echo 
"<center>Invalid Characters:<a href=\"javascript:history.go(-1)\">Go Back</a></center>";  
 Die();
}
if (
ereg("\<"$name)) {
echo 
"<center>Invalid Characters:<a href=\"javascript:history.go(-1)\">Go Back</a></center>";  
 Die();
}
if (
ereg("\["$name)) {
echo 
"<center>Invalid Characters:<a href=\"javascript:history.go(-1)\">Go Back</a></center>";  
 Die();
}
if (
ereg("\>"$name)) {
echo 
"<center>Invalid Characters:<a href=\"javascript:history.go(-1)\">Go Back</a></center>";  
 Die();
}

if (
ereg("\quot"$name)) {
echo 
"<center>Invalid Characters:<a href=\"javascript:history.go(-1)\">Go Back</a></center>";  
 Die();
}

}

echo 
$text;
echo
"<br>";
echo 
$text2;
echo
"<br>";
echo 
$text3;
echo
"<br>";
}else{

?>

<form action="index.php" method="post">
<input type="text"  name="text"><br>
<input type="text"  name="text2"><br>
<input type="text"  name="text3"><br>
     
    <input type="submit" name="submit" value="demo"><br>
</form>
<?php
}
?>


2
Free PHP Scripts / Re: Contact Us with Captcha
« on: October 07, 2009, 12:20:07 PM »
...  Really nice form.

Thanks for sharing.  :)

Pages: [1]