|
|
 |
Pagrindiniai šio puslapio kurėjai
Ecllips410#>`Puma`<
">counter strike 1.6 pro gaming
[color=green]/************* SAVE SHOUT *****************/
// This takes the post vars[/color]
extract($_POST);
[color=green]// This will store any error message[/color]
$errorMsg = "";
[color=green]// This executes the script once submit is clicked.[/color]
if($submit) {
if(!$name) $errorMsg.="You need to input a name! ";
elseif(!$shout) $errorMsg.="You need to make a shout! ";
elseif(($name=="Name") || ($shout=="Message")) $errorMsg.="Slacker! Say something mate. ";
[color=green]// Good, now the essentials are taken care of! "
// Let's make the name display a link if there is a site specified.[/color]
else {
if($site) $author = "$name";
else $author = $name;
[color=green]// Now we should open the file, or make it if it's not there![/color]
$handle = fopen($filename,"a");
[color=green]// Date...[/color]
$date = strftime("%D");
$time = strftime("%T");
$ipaddr = $REMOTE_ADDR;
removeBadWords($shout);
[color=green]// this is how a shout will be stored in your database file[/color]
[color=green]// you can change this to your taste but do remember to change the code reading the file[/color]
$data = "$author | $date | $time | $ipaddr | $shoutn";
fwrite($handle,"$data");
fclose($handle);
}
}
echo $errorMsg; |
|
 |
|
|
|
|