Hallo,
ich bin schon am verzweifeln, ich hoffe mal das die Profis unter euch mir helfen können. Ich habe ein Formular und selbst wenn ich alle Felder ausfülle, wird immer gemeldet das nicht alle Felder ausgefüllt sind.
Ich denke mal das es an den Checkbox liegt, aber irgendwie sehe ich den Wald vor lauter Bäumen nicht mehr.
Hoffe es ist OK wenn ich hier den Code Poste:
Meine HTML Teil:
Hier der PHP Code:
Schon mal danke danke danke wenn ihr mir helfen könnt.
Grüße
Pepper
ich bin schon am verzweifeln, ich hoffe mal das die Profis unter euch mir helfen können. Ich habe ein Formular und selbst wenn ich alle Felder ausfülle, wird immer gemeldet das nicht alle Felder ausgefüllt sind.
Ich denke mal das es an den Checkbox liegt, aber irgendwie sehe ich den Wald vor lauter Bäumen nicht mehr.
Hoffe es ist OK wenn ich hier den Code Poste:
Meine HTML Teil:
HTML:
<div id="content">
<br><br>
<h3>Gutschein ordern:</h3><br>
<br> Ich verschenke folgenden Flug:<br>
<br>
<table >
<col width="55">
<col width="10">
<col width="50">
<col width="50">
<col width="10">
<col width="50">
<col width="50">
<col width="10">
<form action="kontaktformular-auswerten.php" method="post">
<tr>
<td>Schnupperflug</td>
<td><input type="checkbox" name="flug" type="checkbox" value="Schnupperflug "></td>
<td></td>
<td>Standartflug </td>
<td><input type="checkbox" name="flug" type="checkbox" value="Standartflug "></td>
<td></td>
<td>Panoramaflug </td>
<td><input type="checkbox" name="flug" type="checkbox" value="Panoramaflug "></td>
</tr>
<tr>
<td>Thermikflug </td>
<td><input type="checkbox" name="flug" type="checkbox" value="Thermikflug "></td>
<td></td>
<td>Gipfelflug </td>
<td><input type="checkbox" name="flug" type="checkbox" value="Gipfelflug "></td>
<td></td>
<td>Seenflug </td>
<td><input type="checkbox" name="flug" type="checkbox" value="Seenflug "></td>
</tr>
</table>
<br>
<br>
Bergfahrt:
<table>
<form action="kontaktformular-auswerten.php" method="post">
<tr>
<td>inkl. Bergfahrt </td>
<td><input type="checkbox" name="Berg" type="checkbox" value="Bergfahrt "></td></tr>
</table>
<br>
Name des Gutscheininhabers:<br>
<br>
<table >
<col width="70">
<col width="180">
<col width="10">
<col width="50">
<col width="80">
<form action="kontaktformular-auswerten.php" method="post">
<tr>
<td>Anrede:</td>
<td><select name="Ganrede" size="1"><option>Herr</option>
<option>Frau</option><option>Familie</option></select></td></tr>
<tr>
<td>Vorname:</td>
<td><input type="text" name="Gvname" value=""> </td>
<td></td>
<td>Name:</td>
<td><input type="text" name="Gname" value=""> </td>
</tr>
</table>
<br>
<br>
Info´s für den Piloten:<br>
<br>
<table >
<form action="kontaktformular-auswerten.php" method="post">
<tr>
<td>Gewicht:</td>
<td><input type="text" name="gw" value="" size="5" maxlength="5"> </td>
<td></td>
<td>Größe (cm):</td>
<td><input type="text" name="gl" value="" size="5" maxlength="5"> </td>
<td>Alter:</td>
<td><input type="text" name="al" value="" size="5" maxlength="5"> </td>
</tr>
</table>
<br>
<br>
Teilen Sie uns bitte noch Ihre Adresse mit:<br>
<br>
<table >
<col width="70">
<col width="180">
<col width="10">
<col width="50">
<col width="80">
<form action="kontaktformular-auswerten.php" method="post">
<tr>
<td>Anrede:</td>
<td><select name="Anrede" size="1"><option>Herr</option>
<option>Frau</option><option>Familie</option></select></td></tr>
<tr>
<td>Vorname:</td>
<td><input type="text" name="vname" value=""> </td>
<td></td>
<td>Name:</td>
<td><input type="text" name="name" value=""> </td>
</tr>
<tr>
<td>Strasse:</td>
<td><input type="text" name="strasse" value=""> </td>
<td></td>
<td>Nr.:</td>
<td><input type="Text" name="nr" value="" size="5" maxlength="5"></td>
</tr>
<tr>
<td>Ort:</td>
<td><input type="Text" name="ort" value=""></td>
<td></td>
<td>PLZ:</td>
<td><input type="text" name="plz" value=""size="5" maxlength="5"> </td>
</tr>
<tr>
<td>Telefon:</td>
<td><input type="Text" name="telefon" value=""></td>
</tr>
<tr>
<td>Email:</td>
<td><input type="Text" name="email" value=""></td>
</tr>
</table>
<br>
<form action="kontaktformular-auswerten.php">
<p>Geben Sie Ihre Zahlungsweise an:</p>
<p>
<input type="radio" name="Zahlmethode" value="ueberweisung">Überweisung
<input type="radio" name="Zahlmethode" value="rechnung"> Rechnung<br>
</p>
</form>
<table>
<form action="kontaktformular-auswerten.php">
<tr>
<td colspan=2><br>
Gutscheintext:<br><textarea name="Nachricht" cols="30" rows="5"></textarea>
</td>
</tr>
</table>
<br>
<table >
<form action="kontaktformular-auswerten.php" method="post">
<tr>
<td align="center" colspan="2"><input name="Send" type="submit" value="Senden">
<input name="Reset" type="reset" value="Löschen"></td>
</tr>
</table>
<input checked name="agb" type="checkbox" value="AGB Akzeptiert"> AGB´s gelesen und akzeptiert.
</div>
Hier der PHP Code:
PHP:
<html>
<head>
<title>Gutschein ordern</title>
</head>
<body>
<?php
$Empfaenger = "info@rohtec.net";
if($_REQUEST['Send'])
{
if(empty($_REQUEST['Anrede'])|| empty($_REQUEST['vname']) || empty($_REQUEST['name']) || empty($_REQUEST['strasse'])|| empty($_REQUEST['nr'])
|| empty($_REQUEST['ort'])|| empty($_REQUEST['plz'])|| empty($_REQUEST['telefon'])|| empty($_REQUEST['email'])
|| empty($_REQUEST['Ganrede']) || empty($_REQUEST['Gname']) || empty($_REQUEST['Gvname']) || empty($_REQUEST['gr'])
|| empty($_REQUEST['gw']) || empty($_REQUEST['al']) || empty($_REQUEST['Nachricht']) || empty($_REQUEST['ueberweisung'])
|| empty($_REQUEST['rechnung']))
{
echo"Bitte gehen Sie <a href=\"javascript:history.back();\">zurück</a> und füllen Sie alle Felder aus!";
}
else
{
$Mailnachricht = "Gutschein geordert: \n\n";
while(list($Formularfeld, $Wert)=each($_REQUEST))
{
if($Formularfeld!="Send")
{
$Mailnachricht .= $Formularfeld.": ".$Wert."\n";
}
}
$Mailnachricht .= "\nDatum/Zeit: ";
$Mailnachricht .= date("d.m.Y H:i:s");
$Mailbetreff = "Kontakt: ";
$Mailbetreff .= "Informationsmaterial";
mail($Empfaenger, $Mailbetreff, $Mailnachricht, "From: ".$_REQUEST['Email']);
echo"Vielen Dank für Ihr Interesse!";
}
}
else
{
echo"Ein Fehler ist aufgetreten. Bitte gehen Sie auf diese <a href=\"kontaktformular.php\">Seite</a>.";
}
?>
</body>
</html>
Schon mal danke danke danke wenn ihr mir helfen könnt.
Grüße
Pepper