Hi!

I'm quite new in drupal development, so my question may be an easy one :-) I was happy to find and install newsletter and mimemail module for sending newsletters, first time it seemed to be an easy issue to make good looking html newsletters... but, I followed the instructions of both modules and what I'm not able to solve right now: how to add a background image for the newsletter in the css.
What I did: placed the "mail.css" to the template folder of the site, created an eDM folder in the template's image directory and created a newsletter content. The content is "full html", having the lines above:

<div id="wrap">
	<div id="header">
              <h1>Wellcome!</h1>	
              <p>Some text will come here</p>
        </div>
	<div id="intro">
		<h2>Intro</h2>
		<p>some text will come here</p>
		<img src="/sites/all/themes/sitetheme/images/eDM/background.gif" /></div>
	</div>
</div>

The css has the lines above:

body {margin:30px; padding:0px; background-color:#131211;}  
#wrap {background-image:url('/images/eDM/background.gif');background-repeat: repeat-y;}
#header {background:url('/sites/all/themes/sitetheme/images/eDM/header.gif') no-repeat;color: #FF000A;}
h1 {color:orange; text-align:center;}
h2 {color:#FF000A; }
p {font-family:"Times New Roman"; font-size:12px;}

AND the problem is: while Only local images are allowed. works fine, inserts the picture in the newsletter, the css embended pictures are not sent... (neither with short path (/images/eDM/background.gif), or full path (sites/all/themes...))

Any idea, how to solve this issue?!

Comments

swood’s picture

The easiest thing to do is to replace the image with a base64 encoded image. Modify your css so that the background image would like something like:

#wrap {background:url(data:image/gif;base64, xxxbase64dataxxx) no-repeat; color: #FF000A; }

There are several utilities available on the internet for converting an image into base64.