We would like to start sending some HTML email, but I don't want it
if its not CSS based preferably.
Most email clients handle styles very well, but webmail systems need
to contend with spam that can take over the whole interface (remove
the delete button, display their own ads, etc.), and so such systems
remove a *lot* of the CSS control.
You will need to use tables for layout. This is because most webmail
systems will strip or otherwise deactivate any position values, and
floats and clears are unpredictable. I've had a tough time with
margins, too. So layout with tables.
Margins seem ok. Background images are stripped by some webmail, but
only if in CSS: using the HTML background and bgcolor attributes seem
to work fine. Keep in mind that many webmail systems by default will
not load external images.
"But HTML attributes are inline!" you cry. Well, the linked
stylesheets (link tags and @imports) and embedded stylesheets in the
head are also stripped. Embedded stylesheets that declare id or class
selectors were at one point filtered by Hotmail and (I think) an
early version of Gmail, although I'm not sure of the current state.
So the only CSS you have is in your HTML tag's inline style attribute.
So, in summary:
- tables for layout
- CSS for fonts, colors, and margins only
- inline styles in the style attribute only
And since much of this is due to defensive measures, it's not likely
to get better as older browsers die off.
--
Ben Curtis : webwright
bivia : a personal web studio
http://www.bivia.com
v: (818) 507-6613
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/