Hallo
Ich habe ein Gästebuch zu einem Nachrichten-Formular umgestaltet. Die Personen AA bis pp können so einander Nachrichten schreiben, welch in ihre .txt Datei gespeichert werden. Nun werden sie da aber nicht mehr gespeichert. Ist im Quelltext etwas falsch?:
<body>
<a href="gb01.php">zurück</a>
<form name="eintragsform" method="post" action="eintrag01.php">
<table width="374" border="0">
<tr>
<td width="70"><span class="Stil1">Empfänger:</span></td>
<td width="307"><label>
<select name="select">
<option value="01">AA</option>
<option value="02">BB</option>
<option value="03">cc</option>
<option value="04">dd</option>
<option value="05">ee</option>
<option value="06">ff</option>
<option value="07">gg</option>
<option value="08">hh</option>
<option value="09">ii</option>
<option value="10">jj</option>
<option value="11">kk</option>
<option value="12">ll</option>
<option value="13">mm</option>
<option value="14">nn</option>
<option value="15">oo</option>
<option value="16">pp</option>
</select>
</label></td>
</tr>
<tr>
<td><span class="Stil1">Eintrag:</span></td>
<td width="307"><textarea name="text" cols="35" rows="8"></textarea> </tr>
<tr>
<td><span class="Stil1"></span> </td>
<td width="307">
<div align="left">
<input type="submit" name="Submit1" value="Eintragen">
</div> </td>
</tr>
</table>
</form>
<?php
$date = (date ("d.m.Y"));
if ($text != "")
{
$text = trim($text);
$text = ltrim($text);
$text = ereg_replace ("\n", "<BR>", $text);
if ($select == "01")
{
$fp = fopen("/01.txt", "a");}
if ($select == "02")
{
$fp = fopen("/02.txt", "a");}
if ($select == "03")
{
$fp = fopen("/03.txt", "a");}
if ($select == "04")
{
$fp = fopen("/04.txt", "a");}
if ($select == "05")
{
$fp = fopen("/05.txt", "a");}
if ($select == "06")
{
$fp = fopen("/06.txt", "a");}
if ($select == "07")
{
$fp = fopen("/07.txt", "a");}
if ($select == "08")
{
$fp = fopen("/08.txt", "a");}
if ($select == "09")
{
$fp = fopen("/09.txt", "a");}
if ($select == "10")
{
$fp = fopen("/10.txt", "a");}
if ($select == "11")
{
$fp = fopen("/11.txt", "a");}
if ($select == "12")
{
$fp = fopen("/12.txt", "a");}
if ($select == "13")
{
$fp = fopen("/13.txt", "a");}
if ($select == "14")
{
$fp = fopen("/14.txt", "a");}
if ($select == "15")
{
$fp = fopen("/15.txt", "a");}
if ($select == "16")
{
$fp = fopen("/16.txt", "a");}
fputs($fp, "<HR>AA: <BR> $text ($date)<BR>\n");
fclose($fp);
print ("<script language="JavaScript">Ziel()</script>");
}
?></p>
</body>
Danke