The "Freeola Customer Forum" forum, which includes Retro Game Reviews, has been archived and is now read-only. You cannot post here or create a new thread or review on this forum.
So, on Rob's recommendation, I dug out my copy of dreamweaver and made my table, now, I want the results to be sent out to an e-mail address, could someone tell me what I need to do now?
if ($interest_corporatecommunications == "checkbox") {
$interest_corporate = "Interested in Corporate Communications";
};
if ($interest_tvprogramme == "checkbox") {
$interest_tv = "Interested in TV Programme Production";
};
if ($interest_webclips == "checkbox") {
$interest_web = "Interested in Web Clips";
};
if ($interest_memories == "checkbox") {
$interest_memory = "Interested in Memories Are Made Of This";
};
if ($interest_memories == "checkbox") {
$interest_memory = "Interested in Memories Are Made Of This";
};
if ($interest_training == "checkbox") {
$interest_train = "Interested in Training Videos";
};
if ($interest_charity == "checkbox") {
$interest_charities = "Interested in Charity Services";
};
if ($interest_consultation == "checkbox") {
$interest_consultations = "Interested in Consultation";
};
if ($interest_websites == "checkbox") {
$interest_webs = "Interested in Web Sites!";
};
if ($email == "") {
$errors .= "Sorry, you have not given an E-mail address
";
}
if ($name == "") {
$errors .= "Sorry, you have not given your name";
}
if ($errors) {
echo "Sorry, there were some errors with your submittal:
$errors
Please press the back button on your browser and correct these mistakes";
} else {
$recip = "[email protected]";
$from = $email;
$subject = "Form Results";
$body = "Form results:
Name = $name
Position = $position
Department = $department
Company = $company
Address = $address
City = $city
Post Code = $postcode
Telephone = $telephone
E-Mail = $email
Comments = $comments
Interest =
$interest_corporate
$interest_tv
$interest_web
$interest_memory
$interest_train
$interest_charities
$interest_consultations
$interest_webs";
if (mail ($recip, $subject, $body, "From: $from")) {
echo "
} else {
echo "There was an error, an E-mail has been sent to the system administrator and it will be corrected shortly. We appologise for any inconvienience (sp?)";
mail ($recip, "The mail script f*cked up", "Details:\n\n$body", "From: $from");
}
}
?>
But the Javascript bit doesnt work..
if ($email == "") {
$errors .= "Sorry, you have not given an E-mail address
";
}
if ($name == "") {
$errors .= "Sorry, you have not given your name";
}
// OK, you get the idea, one for each of the required positions. You can do
// this later
if ($errors) {
echo "Sorry, there were some errors with your submittal:
$errors
Please press the back button on your browser and correct these mistakes";
} else {
$recip = "[email protected]"; // oi, type your email here
$from = $email; // Actually... what's teh variable that holds the sender's E-mail address?
$subject = "Form Results";
$body = "Form results:
Name = $name
Position = $position
Department = $department
Company = $company
Address = $address
City = $city
Post Code = $postcode
Telephone = $telephone
E-Mail = $email
Comments = $comments
Interest = $interest_corporatecommunications
$interest_tvprogramme
$interest_webclips
$interest_memories
$interest_training
$interest_charity
$interest_consultation
$interest_websites";
if (mail ($recip, $subject, $body, "From: $from")) {
echo "Thank you, your submittal was recieved with thanks";
} else {
echo "There was an error, an E-mail has been sent to the system administrator and it will be corrected shortly. We appologise for any inconvienience (sp?)";
mail ($recip, "The mail script ****** up", "Details:\n\n$body", "From: $from");
}
}
?>
There you go. It may need some adjusting but it'll be an experience for you.
There'll almost certainly be some errors though, have fun!
(go)errors, that mean your **** then?? :)
what does /n mean?
\n (backslash) it means "newline". It's the same as a carriage return. They're
a bit quirky though, you may have to replace them with real carriage returns.
Don't worry, the function will work OK, it just looks ***** :)
heh, k. What do I have to do to the form to make it work with this?
The best thing for you to do is go and look at HOTSCRIPTS.COM under PERL (that's basically CGI) for files that process forms.
You should be able to find a free file with some good documentation on how to set it up.
It's not that difficult, and all it really involves is setting the URL of where that script is stored on your server.
You'll also need to change a few things within the script (unless you find a nice straight forward one) but it's all very very simple.
The help pages on this site (for freeola users) help explain the details of using CGI scripts on freeola, but you may need to find similar details from your own provider if your not with freeola.
So, on Rob's recommendation, I dug out my copy of dreamweaver and made my table, now, I want the results to be sent out to an e-mail address, could someone tell me what I need to do now?