Thread: Create (not add) an attachment
Results 1 to 1 of 1
Related
-
How to create web service with C# Forum: ASP Forum
Replies: 1 -
How to create this counter Forum: CSS Forum
Replies: 0 -
Requesting an attachment Forum: ASP Forum
Replies: 6
-
09-27-2004, 09:08 PM #1
Create (not add) an attachment
I have a php script that takes data from a form and emails it to my email account. It sends the information as a HTML email. Pretty simple stuff.
How might I get it to send the HTML email data as an attached .html file?
I know how to attach existing files to a php email, but I don't know anything about dynamically creating an html file to attach to a php email.
I'd appreciate it if someone could point me in the right direction.
Below is an example of my existing code, where I create an HTML-style email. I want instead to send everything contained in $messagebody as an .html file attachment.
$headers = "From: Me<email@email.com>\r\n";
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
$subject = "Online Application for Employment";
$messagebody = "<html><head></head><body>";
$messagebody .= "<B>Email Data Here</B>";
$messagebody .= "</body></html>";
@mail("email@email.com",$subject,$messagebody,$headers);
-

Reply With Quote

Web application to monitor websites
06-12-2013, 08:28 AM in Internet Services