sixx66
Mitglied
Hallo zusammen!
Leider bin ich in Sachen PHP absolut hilflos und stehe nun vor folgendem Problem:
Nach dem Abschicken dieses Bestellformulars soll der Kunde eine kurze Mail zur Bestätigung seiner Bestellung bekommen.
Das bisher verwendete Script kann das leider nicht.
Gibts vielleicht einen Weg das bestehende Script zu erweitern?
Vielen Dank schon mal!
Leider bin ich in Sachen PHP absolut hilflos und stehe nun vor folgendem Problem:
Nach dem Abschicken dieses Bestellformulars soll der Kunde eine kurze Mail zur Bestätigung seiner Bestellung bekommen.
Das bisher verwendete Script kann das leider nicht.
Gibts vielleicht einen Weg das bestehende Script zu erweitern?
PHP:
<?
/* Welcome to WebWorkz Ware Form-2-Mail. Please set the following variables to the proper settings. More detailed instructions can be found in the advancedform2mail.txt file. If you receive an error with this script, send a ZIP file of your script along with a detailed error message to justin@webworkznetwork.com. Please at least attempt a few times to get it working before you e-mail. I don't want to receive an e-mail because you accidentally forgot a letter in your e-mail address... :)
Hope you enjoy the script and I hope it makes it easier for you to get mail from your web site to your mailbox. */
// Up-To 20 domain names that can use this script ***DO NOT PUT WWW IN FRONT***
// (Example: webworkznetwork.com)
$domains = Array (
'1' => 'palikanon.de',
'2' => 'buddhareden.de',
'3' => '',
'4' => '',
'5' => '',
'6' => '',
'7' => '',
'8' => '',
'9' => '',
'10' => '',
'11' => '',
'12' => '',
'13' => '',
'14' => '',
'15' => '',
'16' => '',
'17' => '',
'18' => '',
'19' => '',
'20' => '');
// Error color selection. (Example: blue)
$errorcolor = "yellow";
// Thank you message. (Example: Thanks for submitting our web form)
$thankyoumessage = "Herzlichen Dank für Ihre Angaben. Wir werden uns in Kürze bei Ihnen melden.";
// Enter e-mail addresses (Example: 1 => user@domain.com, => me@myhouse.com)
//
$emailaddresses = Array (
'1' => 'verlag.beyerlein@t-online.de',
'2' => '',
'3' => '',
'4' => '',
'5' => '',
'6' => '',
'7' => '',
'8' => '',
'9' => '',
'10' => '',
'11' => '',
'12' => '',
'13' => '',
'14' => '',
'15' => '',
'16' => '',
'17' => '',
'18' => '',
'19' => '',
'20' => '');
/* ----------------- DO NOT EDIT PAST THIS LINE -------------- */
IF (!isset($errorpage) and !isset($successpage) and isset($formtitle))
{
include ("header.inc");
echo ("<center><font size=\"+3\">$formtitle</font></center>");
}
$errorcount = 0;
$domaincount = 0;
while (list ($arrayid, $name) = each ($domains))
{
$name2 = "www." . $name;
IF ($HTTP_HOST == $name or $HTTP_HOST == $name2)
{
++$domaincount;
}
}
IF ($domaincount == 0)
{
echo ("<b>Improper Access.</b>");
}
ELSE
{
IF (isset($required))
{
$array = split(",", "$required");
while (list ($arrayid, $name) = each ($array))
{
IF ($$name == "")
{
++$errorcount;
IF (isset($errorpage))
{
header("Location: $errorpage");
exit();
}
ELSE
{
echo ("<b>Required Field <font color=\"$errorcolor\">'$name'</font> Left Blank.</b><br>");
}
}
}
}
IF ($errorcount == 0)
{
$message = "\n";
$message .= "Folgendes wurde uebermittelt:\n\n";
IF (isset($formtitle))
{
$message .= "$formtitle\n\n";
}
while (list ($var, $val) = each ($HTTP_POST_VARS))
{
IF ($var != "required" and $var != "subject" and $var != "errorpage" and $var != "successpage" and $var != "formtitle" and $var != "sendto")
{
$message .= "$var: $val\n";
}
}
$array2 = split(",", "$sendto");
while (list ($arrayid, $emailselections) = each($array2))
{
$email = $emailaddresses[$emailselections];
$mail = mail($email, $subject, $message, "Bestellung beim Beyerlein-Steinschulte Verlag\r\n");
IF (!$mail)
{
echo ("<p><b><font color=\"$errorcolor\">Error Sending E-Mail. Please Try Again Later.</b></font>");
exit();
}
}
IF (isset($successpage))
{
header("Location: $successpage");
exit();
}
ELSE IF (!isset($successpage))
{
echo ("$thankyoumessage");
}
}
ELSE
{
echo ("<p><b><font color=\"$errorcolor\">Please Click 'Back' and Fix The Above Errors.</font></b>");
}
}
echo ("<p><center>This Script Provided Free By WebWorkz Ware. This, and other free scripts are available at <A HREF=\"http://www.webworkzware.com\">http://www.webworkzware.com</a>.</center>");
include ("footer.inc");
?>
Vielen Dank schon mal!