kan iemand nog eens kijken wat ik nu verkeerd doe. ik heb vanalles geprobeerd maar geen aanknopingspunt meer om verder te gaan.
ik zou graag willen dat ook de afzender zijn emailadres (wat ingevuld wordt in het formulier) zichtbaar wordt op de feedback die ik binnenkrijg. zodat ik een reply kan doen. nu krijg ik steeds het emailadres van de hosting als afzender.
het enige wat ik aan dit standaard script heb veranderd is dat ik op regel 4 dit
$MailFromAddres="From: ".$_POST['requiredemail'];
heb toegevoegd en op regel 49/50
heb ik
$MailFromAddres,
toegevoegd aan
mail( $MailToAddress, $MailSubject, $Message, "Content-Type: text/html; charset=ISO-8859-1\r\nFrom: ".$email."\r\nBCc: ".$MailToCC);
header("Location: ".$redirectURL);
dit is het volledige script maar zo wordt mijn hele output verkracht.
<?php
$MailToAddress = "
[email protected]"; // your email address
$MailFromAddres="From: ".$_POST['requiredemail'];
$redirectURL = "reply.php"; // the URL of the thank you page.
# optional settings
$MailSubject = "primastyle design lab - feedback"; // the subject of the message you will receive
$MailToCC = ""; // CC (carbon copy) also send the email to this address (leave empty if you don't use it)
# in the $MailToCC field you can have more then one e-mail address like "
[email protected],
[email protected],
[email protected]"
# If you are asking for an email address in your form, you can name that input field "email".
# If you do this, the message will apear to come from that email address and you can simply click the reply button to answer it.
# You can use this scirpt to submit your forms or to receive orders by email.
# You need to send the form as POST!
# If you have a multiple selection box or multiple checkboxes, you MUST name the multiple list box or checkbox as "name[]" instead of just "name"
# you must also add "multiple" at the end of the tag like this: <select name="myselect[]" multiple>
# and the same way with checkboxes
# This script was made by George A. & Calin S. from Web4Future.com
# There are no copyrights in the e-mails sent and we do not ask for anything in return.
# DO NOT EDIT BELOW THIS LINE ============================================================
# ver. 1.2
$Message = "";
if (!is_array($HTTP_POST_VARS))
return;
reset($HTTP_POST_VARS);
while(list($key, $val) = each($HTTP_POST_VARS)) {
$GLOBALS[$key] = $val;
if (is_array($val)) {
$Message .= "<b>$key:</b> ";
foreach ($val as $vala) {
$vala =stripslashes($vala);
$Message .= "$vala, ";
}
$Message .= "<br>";
}
else {
$val = stripslashes($val);
if (($key == "Submit") || ($key == "submit")) { }
else { if ($val == "") { $Message .= "$key: - <br>"; }
else { $Message .= "<b>$key:</b> $val<br>"; }
}
}
} // end while
$Message = "<font face=verdana size=2>".$Message;
mail( $MailToAddress, $MailSubject, $MailFromAddres, $Message, "Content-Type: text/html; charset=ISO-8859-1\r\nFrom: ".$email."\r\nBCc: ".$MailToCC);
header("Location: ".$redirectURL);
?>