CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • How to embed images?
Pages: [1]

Author Topic: How to embed images?  (Read 1029 times)

micheas

  • I’m new here
  • *
  • Posts: 14
  • Karma: 1
    • Green Campaigns
How to embed images?
January 16, 2010, 06:20:58 pm
In order to embed images I would need to attach the image, (easy enough)
and then go back and adjust the image source like so:
Code: [Select]
<img src="cid:email_banner_6b352e0031e74d13b651ad66b3818520jpg" alt="" width="500" height="133" />

The problem is that civimail produces

Code: [Select]
Content-Transfer-Encoding: base64
Content-Type: image/jpeg; name="email_banner_6b352e0031e74d13b651ad66b3818520jpg"
Content-Disposition: attachment; filename="email_banner_face500_6b352e0031e47d13b651ad66b3818520jpg"
Which does not include the Content-ID: email_banner_6b352e0031e74d13b651ad66b3818520jpg
tag.

If I knew where in civimail this is being set, I could quickly add it.

Any suggestions on where to look?

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: How to embed images?
January 16, 2010, 10:24:34 pm

i'm pretty sure its: packages/Mail/mime.php

that generates that code. you might also want to apply this patch:

http://fisheye2.atlassian.com/browse/CiviCRM/branches/v3.0/CRM/Utils/File.php?r1=24848&r2=25836

to get a filename with a valid extension

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • How to embed images?

This forum was archived on 2017-11-26.