View Full Version : file attachments

12-31-2005, 07:28 AM
Hi, i have a php script to send text form, but i would like to attach 3 photo accepting jpg / png files only. I try coding it myself but always get some error or it go through but i dont receive any in my inbox! I trying to send the files as an attachment to my inbox. Can someone help me out modfying the following codes?


echo "<font face='Verdana' size='3'><b>IP Address= $ip</b>";
$TS = date("l, F d Y h:i a",time());
$salute = $_POST['salute'] ;
$Name = $_POST['Name'] ;
$Email = $_POST['Email'] ;
$Type = $_POST['Type'] ;
$msg = $_POST['msg'] ;

$recipient = "email@domain.com";
$subject = "Contact Form";

$message = "Time Stamp: $TS \n";
$message .= "IP: $ip \n";
$message .= "Salutation: $salute \n";
$message .= "Name: $Name \n";
$message .= "Email: $Email \n";
$message .= "Type: $Type \n";
$message .= "Message: $msg \n";

$headers = "From: email@domain.com";

header( "Location: http://www.domain.com/hey.html" );


Thank you

12-31-2005, 11:42 PM
it would do you good to read this page: http://www.sitepoint.com/print/advanced-email-php