Witam.
Moj problem dotyczy tego, ze podczas wyslania formularza na moj email dochodzi tylko " last_name" , reszta nie przychodzi. Czy ktos moglby mi wytlumaczyc dlaczego? Wydaje mi sie ze ze zmiennymi wszystko jest okey, zalezy mi zeby doszła wiadomosc z text_area, first name, last name, oraz email(from), pozdrawiam.
<?php if(isset($_POST['submit'])){ $to = "mojemail@email.pl"; // moj adres $from = $_POST['email']; // adres wysylajacego $first_name = $_POST['first_name']; // imie $last_name = $_POST['last_name']; // nazwisko $subject = "Form submission"; $subject2 = "Copy of your form submission"; $message = $first_name . "" . $last_name . " wrote the following:" . "\n\n" . $_POST['message']; $message2 = "Here is a copy of your message " . $first_name . "\n\n" . $_POST['message']; $headers = "From:" . $from; $headers2 = "From:" . $to; mail($to,$subject,$message,$headers); mail($from,$subject2,$message2,$headers2); // wysylanie kopii do osoby wysylajacej echo "Wiadomość wysłana " . $first_name . ", Dziekujemy!"; } ?>
KOD HTML
<div class="dum">Imie: </div> <input type="text" name="First"> <div class="dum"> Email: </div> <input type="text" name="from" maxlength="50" size="4"><div class="dum"> Nr tel: </div><input type="text" name="last_name" maxlength="13" size="13"> <textarea rows="4" cols="50" name="message"></textarea> <input type="submit" name="submit" value="Wyslij"> <a name="contact" id="contact"></a>