I have an HTML form, with an external PHP script, which I am trying to use to email me the images a user uploads. The script is pretty rudimentary, but the text portions work. The HTML part looks like this:
<script>
<p>Please use this area to upload at least three picrures.</p>
<table>
<tr><td align="left"><input type="file" name="pic1" /></td></tr>
<tr><td align="left"><input type="file" name="pic2" /></td></tr>
<tr><td align="left"><input type="file" name="pic3" /></td></tr>
<tr><td align="left"><input type="file" name="pic4" /></td></tr>
</table>
</script>
And the PHP Script looks like this:
<script>
<?php
extract($_POST);
$msg =<<<Message
Email Sent from Soul Exposure Photography Form Page
General Information
I_am_here_to: <b>$apply</b>
FirstName: <b>$fname $lname</b>
Address1: $addr1
Address2: $addr2
City: $city
State: $state
Zip: $zip
Email Address: $Email
Phone: $phone
Date_of_Birth: $BdateMonth $BdateDay $BdateYear
Gender: $gender
Modeling Information
Height: $height
Weight: $weight
Bra_Size: $bra
Waist: $waist
Hips: $hips
Dress_Size: $dress
Shoe_Size: $shoes
Eye_Color: $eyes
Hair_Color: $hair_color
Types of Modeling
Glamour: $glamour
Pinup: $pinup
Body_Parts: $bodyparts
Print: $print
Swimwear: $swimwear
Lingerie: $lingerie
Semi_Nude: $seminude
Artistic: $artistic
Playboy_Type: $playboy
Erotic: $erotic
Fetish: $fetish
Upload your Images
Image1: $pic1
Image1: $pic2
Image1: $pic3
Image1: $pic4
In Your Own Words
Get_From_Modeling: $get_from_modeling
Perfect_Session: $perfect_session
Event_Promo_Email: $event_email
Message;
the above terminator was moved from where it's commented out below
$to = "saprod_sj@yahoo.com, smeghead57@comcast.net";
$subject = "Soul Exposure Photography Profile Form Submission";
The following should be a real email address like:
"From: \"$Fname $Lname\" <$Email>\n\n";
$mailheaders = "From: SoulX Photo Website\n\n";
$Result = mail($to,$subject,$msg,$mailheaders);
echo "<h2>Hey $Fname, thanks for your submission</h2>\n";
header('Location: http://www.soulxphoto.com/');
#Message; This lable was misplaced.
?>
</script>
Thanks,
nick