Warning: fopen(szpil.php.txt): failed to open stream: Permission denied in /home3/ma/mako/szpil.php on line 37
Warning: fwrite(): supplied argument is not a valid stream resource in /home3/ma/mako/szpil.php on line 38
Warning: fclose(): supplied argument is not a valid stream resource in /home3/ma/mako/szpil.php on line 39
a oto kod pliku:
Kod: Zaznacz cały
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Ble ble</title>
</head>
<body>
<p>ty był tekst do komentowania</p>
<FORM method="post">
<b>Twoja nazwa(nick):</b><BR><INPUT name="name" type="text" size="55"><BR>
<b>Treść komentarza:</b><BR>
<TEXTAREA name="message" rows=10 cols=55 wrap=virtual>
</TEXTAREA><BR>
<INPUT name="submit" type="submit" value="Dojebaj komentarz">
</FORM>
<p align="center" class="style1">Wasze komentarze:</p>
<?
if ($message)
{
$message = ereg_replace("\r\n\r\n", "\n<P>", $message);
$date = date("F j Y, h:i a");
$message = "<B>$name </B> -- $date<P> $message <BR><HR>";
$fp = fopen (basename($PHP_SELF) . ".comment", "a");
fwrite ($fp, $message);
fclose ($fp);
}
@readfile(basename(($PHP_SELF . ".comment")));
?>
</body>
</html>
