Jump to content

johnx

New Members
  • Posts

    1
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

johnx's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hello, I have big problem here. I need to create HTML email with images displayed in the body of the mail and I need to attach PDF document as normal file attachment. This is easy by using phpMailers functions AddEmbeddedImage and addAttachment, but some emails clients do not show pdf (file) attachment if I use AddEmbeddedImage before/after.. Images in the body must works in offline too (I can not use external links to show images in the email body)... Can somebody help? There is example of source code: <?php $mail = new phpmailer(); $mail->From = 'mail.mail@mailer.com'; $mail->Subject = 'PDF document'; $mail->IsHTML(true); $mail->AddAddress('someone@mail.com'); $mail->AddAttachment('document.pdf','document.pdf',"base64","application/pdf"); $mail->AddEmbeddedImage("logo.gif","weblogo","weblogo.gif","base64","image/gif"); $mail->Body = "<table><tr><td>Ahoj blabal</td><td><img src='cid:weblogo'></td></tr></table>"; $mail->Send(); ?>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.