title: C# html Email - Div/Text over Image
body: <p>I'm trying to create a nice looking email for when a user registers on my website however I am not able to display the text over an image the usual way. Instead, the texts are displayed below the image.</p>
  
  <p>I know I can't use StyleSheets, and that I should stick to CSS 1.4..</p>
  
  <p>I'm having a background image which i'm stretching (by setting its width and height) and I would like to put some text on top of this image. In normal html, I can use css methods such as float: left; position: absolute for the div to be floating over the image. But this doesn't work within the C# code because it gets truncated in most email clients.</p>
  
  <p>The image will only display if it is written in the following way:</p>
  
  <pre><code> &lt;div style='width: 580px; font-family: Calibri; font-size:13px;'&gt;
  
           &lt;img style='height: 45px;   width: inherit;' src='http://www.somedomain.com/mail/background.png' /&gt;
  Test
  Test2
  Test3
  &lt;/div&gt;
  </code></pre>
  
  <p>I tried to embed the code above within a style and it simply doesn't work. For example:</p>
  
  <pre><code>&lt;div style='background:url(images/background.png); position: absolute; top:45px; width:550px; padding: 15px;'&gt; SOME TEXT HERE &lt;/div&gt;
  </code></pre>
  
  <p>OR</p>
  
  <pre><code>&lt;div style='background-image:url(images/background.png); position: absolute; top:45px; width:550px; padding: 15px;'&gt; SOME TEXT HERE &lt;/div&gt;
  </code></pre>
  
  <p>OR</p>
  
  <pre><code>&lt;table&gt;
  &lt;tr&gt;
  &lt;td style="background-image: url(background.png);"&gt;Testing Page&lt;/td&gt;
  &lt;/tr&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>If you change "background-image: url(background.png);" to "background:red;" it works and this is confusing!</p>
  
  <p>How do I make this work properly in most email clients as well? (Gmail, Hotmail, Outlook, Thunderbird, Windows Mail, etc.)</p>
  
  <p>Thanks for any help you can provide :)</p>