Reputation: 533
I'm trying to send an email with HTML content, but it doesn't send formatted.
This is my code,
print OUT "To: $email\n";
print OUT "From: $pedidos\n";
print OUT "CC: $pedidos\n";
print OUT "BCC: $tecnico\n";
print OUT "Subject: $subject\n";
print OUT "Content-type: text/html; charset=iso-8859-1\n\n";
print OUT "<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.0 Transitional//EN'>";
print OUT "<html><head><title>Title</title></head>";
(...more html...)
Any idea?
Thanks!
Upvotes: 1
Views: 530
Reputation: 62099
Well, for one thing, you left out
print OUT "MIME-Version: 1.0\n";
without which your Content-type header doesn't mean anything. I'm assuming that content going to OUT
is correctly being emailed.
Upvotes: 1