html-email

html email with background-image style not shown

五迷三道 提交于 2019-11-27 02:17:36
问题 I am creating an email template which has to display images from external website. I had placed some <img> tags for rendering the images and there are some <td> tags with background-image property set in inline css of the elements. Now, when an email is received in outlook, the images are not displayed (this is expected as the images are not embedded). And I click the download images to see the images properly. The images in <IMG> tag are only shown and the background-image for the <TD> is

HTML email in Gmail - CSS style attribute removed

大憨熊 提交于 2019-11-27 02:06:23
问题 I'm working on an HTML email and I am using MailChimp's Responsive Email Templates in combination with their CSS inliner tool. For the most part, the email looks great across the myriad of email clients, but in Gmail things are horribly misrepresented. If I use Gmail's "Show original" option from the drop down menu next to the reply arrow, the original HTML is different from what is actually displayed in the email client. I can confirm this by inspecting the element with the developer tools.

Is it possible to use display:block on td in HTML email, to achieve responsive table design?

£可爱£侵袭症+ 提交于 2019-11-27 01:39:48
问题 This fantastic article describes how to create responsive tables which scale fabulously to mobile browsers. Now I'm trying to apply the same technique to html emails but display:block just won't seem to work in html emails. To reproduce the issue: Save the following code as an HTML page: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <meta charset="utf-8"> <style type="text/css"> @media only screen and

Background images not working in Outlook 2007 and later

拟墨画扇 提交于 2019-11-27 01:02:35
问题 I made an HTML Email Template that is working fine in most email readers, but the background images are not showing in Outlook 2007, 2010, and 2013. How can I solve the problem? Here's the HTML for the email: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <style type="text/css"> * { padding: 0px;

Has anyone gotten HTML emails working with Twitter Bootstrap?

感情迁移 提交于 2019-11-26 23:48:43
问题 I'm using the premailer-rails3 gem which pulls styles inline for html emails, and I'm trying to get it working with Twitter bootstrap. https://github.com/fphilipe/premailer-rails3 It looks like some styles come in correctly, but not all of them. I'm wondering if anyone has a nice working example of getting their Twitter Bootstrap css (modified or not) into an html email. Thanks! 回答1: If you mean "Can I use the stylistic presentation of Bootstrap in an email?" then you can, though I don't know

How do I write a media query for Gmail?

故事扮演 提交于 2019-11-26 22:07:21
问题 I am trying to write some HTML/CSS for an email but can't get things to show and hide responsively. I have one big table, with two nested tables. Each of the nested tables is a footer that is hidden or shown based on the screen size. Here's the code <style> @media all and (max-width: 768px) { table[table-view=desktop] { display: none !important; } table[table-view=mobile] { display: block; } } @media all and (min-width: 769px) { table[table-view=mobile] { display: none !important; } table

Email issue (send hyperlink in email body) android

老子叫甜甜 提交于 2019-11-26 21:03:26
问题 mIntent = new Intent(Intent.ACTION_SEND); mIntent.putExtra(Intent.EXTRA_SUBJECT, getString("")); mIntent.setType("text/html"); Uri myUri = Uri.parse("http://www.Google.com/"); mIntent.putExtra(android.content.Intent.EXTRA_TEXT,Html.fromHtml("<a href=\""+myUri+"\">Link</a>")); startActivity(android.content.Intent.createChooser(mIntent, "Email:")); I tried the above code but at receiver side I can not get Link. it convert into normal text.. 回答1: Try this one.. It is working for me.. String link

HTML email align text

瘦欲@ 提交于 2019-11-26 20:54:23
问题 I am trying to align a part of text to the right and the other part to the left in an HTML mail but in Outlook the float doesn't work. So basically I am looking for float CSS in Outlook. I know it sounds pretty creepy and text-align or align="" didn't work. Any suggestions? <td> <span style="text-align:left; float:left;"> First part </span> <span style="text-align:right; float:right;"> Second part </span> </td> 回答1: Honestly if you're doing an HTML email I'd stick to using tables. Not all CSS

Send table as an email body (not attachment ) in Python

风格不统一 提交于 2019-11-26 20:00:14
问题 My input file is a CSV file and by running some python script which consists of the python Tabulate module, I have created a table that looks like this below:- tabulate_output or | Attenuation | Avg Ping RTT in ms | TCP UP | |---------------:|---------------------:|---------:| | 60 | 2.31 | 106.143 | | 70 | 2.315 | 103.624 | I would like to send the this table in the email body and not as an attachment using python. I have created a sendMail function and will be expecting to send the table in

Is there an equivalent of CSS max-width that works in HTML emails?

怎甘沉沦 提交于 2019-11-26 18:46:09
问题 I'm trying to create an HTML email that will display properly in all widely used email clients. I'm wrapping the whole email in a table, and I'd like it to have a width that is up to 98% of the available width, but no greater than 800 pixels. Like this: <table style="width:98%; max-width:800px;"> But I'm not doing it that way, since according to this Outlook 2007 does not support the CSS width property. Instead, I'm doing this: <table width="98%"> Is there any way to also set a max-width