I am trying to take information from a web page form, and converting it into a comma or tab delimited file which can then be imported within Excel.
I have no problem having the data sent within an email. Just trying to simplify my adding the data later. (Don't want to have to retype it, or copy and paste it for fear I will mess up.)
The variable I have are:
Code:
<?php
$contact = $_POST['contPref'];
$address = $_POST['eMail'];
$subject = 'EMail from contact us form';
$fname = $_POST['fName'];
$lname = $_POST['lName'];
$street1 = $_POST['street1'];
$street2 = $_POST['street2'];
$city = $_POST['city'];
$state = $_POST['state'];
$zip = $_POST['zip'];
$phone = $_POST['phone'];
$email = $_POST['emailadd'];
$comments = $_POST['comments'];
$mailsend = mail($address, $subject, "Name: $fname $lname
Contact: $contact
Address: $street1
$street2
$city , $state $zip
Phone: $phone
Email: $email
Comments: $comments");
echo $mailsend;
echo $body;
?>
Any help would be appreciated. Thank you very much in advance for your help.
__________________
It's never "just a game" when you're winning.
~ George Carlin ~
|