24-11-2009, 21:17
|
|
|
חבר מתאריך: 03.08.08
הודעות: 717
|
|
עיצוב הודעה מטופס
במ"ב הקוד שלי לטופס יצירת קשר(שמקבל נתונים מהמשתמש בפלאש)
השאלה שלי היא איך לעשות רווח בין הדברים כי במייל שמגיע אליי הכל בשורה אחת ארוכה ולא ברורה
אני רוצה שנגיד יהיה
שם פרטי{אנטר}
אמייל {אנטר}
תוכן הודעה{אנטר}
וכו'
תודה לעוזרים!
קוד PHP:
<?php $toaddress = 'okopel@gmail.com'; $subject = 'פנייה מהאתר'; $what = $_POST['what']; $when = $_POST['when']; $firstname = $_POST['firstname']; $lastname = $_POST['lastname']; $email = $_POST['email']; $message = $_POST['message'] . ' <' . $what . ' ' . $when . ' ' . $firstname . ' ' . $lastname . ' ' . $email . '>'; $from = "From: {$firstname} {$lastname}<{$email}>"; $ok = mail($toaddress, $subject, $message, $from); if ($ok) { echo("&serverResponse=The mail was successfully sent"); } else { echo("&serverResponse=Sorry but the email could not be sent. Please try again!"); } ?>
|