Hi - I am just getting to grips with using php scripts to add functionality to my site. I would very much like to add a simple email script to send me the contents of forms and most important I would like to create a password protected section of my site for members. There are so many options, I would value some suggestions/recommendations. THANKS.
PHP script advice - password protected members’ section & email form?
Hi - I am just getting to grips with using php scripts to add functionality to my site. I would very much like to add a simple email script to send me the contents of forms and most important I would like to create a password protected section of my site for members. There are so many options, I would value some suggestions/recommendations. THANKS.
Can’t get my php form email results to display radios checkboxes?
I can get it to email me ordinary text fields but I also need a checkbox field/s and radio buttons…how do I alter it so I can do that?
My form looks like this:
but php form handler looks like:
/////////// Getting the form values/////////
$name = $_POST['name'];
$email_address = $_POST['email'];
$message = $_POST['message'];
$number = $_POST['number'];
$sex = $_POST['sex'];
/////////// Checking for Email Injection/////////
if ( ereg( "[\r\n]", $name ) || ereg( "[\r\n]", $email_address ) ) {
header('Location: feedback.php' );
}
/////////// Making the Email Message/////////
$email_from = $email_address;
$email_subject = "Birthday Form";
$email_body = "Name: " . $name . " \n
Message: " . $message . " \n
Phone Number: " . $number
Sex: $sex
;
/////////// Sending the Email using the mail() function/////////
$to = "myemail@mysite.uk.com";
$headers = "From: $email_from";
mail($to,$email_subject,$email_body,$headers);
header('Location: feedback.php' );
?>
Where can I find a free script that will email an order made through PayPal to a customer after purchase?
I want a free script, whether .php or .cgi or whatever, that automates the emailing of files to customers who make a purchase through PayPal. I would also the script to not email the file to the customer after payment if they pay by e-check until the check has cleared. If you are only able to satisfy the first part of my request, no problem. I may be able to modify the script after.
PHP email sending?
I have a page with a form in it to send a short message to my email address. The form has three fields: Name, E-mail & Message. The name one is where the sender types his/her name; Email where sender puts their email address, and Message where they type the message (simple)
when the user clicks submit it runs the following php code:
sendEmail($_POST);
function sendEmail($post){
$emailto .= "email@somewhere.com";
$subject .= "Question from " . $post['uname'];
$header .= $post['$uname'];
$message .= $post['umail']." wrote the following:\n\n";
$message .= $post['umessage']."\n\n";
mail($emailto, $subject, $message, $header);
header("LOCATION: contact_sent.php#sent");
}
?>
Problem: when I check the sent message i see the date, the subject, but the sender appears as follows:
nobody@server#.domain.com
Question: How can I do so that the field with the email appears as the sender, or that the field with the name appears as the sender (or maybe both) Thanks