
0
Android 4.4 STILL Not Centering.
Hi all,
As you probably know, Android 4.4 throws a bit of a margin around the body of emails. I saw the fix proposed by James White here: https://blog.jmwhite.co.uk/2015/09/19/revealing-why-emails-appear-off-centre-in-android-4-4-kitkat. I plugged the snippet of code in, but it is still forcing the content to the right. I'm wondering if my max-width (set at 320px) is too wide? Such an annoying issue!! Any help is appreciated.
-P
try to write the parameters for <TD> in this order margin (top-left-bottom-right) this could help otherwise use !important.
Thank you. I know that we've had some problems with "margin" in other email clients. I hesitate to use it just to make Android work and then potentially break other layouts. There wouldn't happen to be something conditional that only Android would pick up? Similar to the "<!--[if mso]>" approach?
I greatly appreciate your response.
In his code he uses margin: 0 !important
Try margin: 0 auto !important
When I used that fix for android 4.4 it did work on litmus results but when I tested Samsung, it was aligned left and not centered so I added auto for left and right margins and it seems to work on both
Stephen - thanks SO much for the 'margin: 0 auto !important' as it worked amazingly!
I wouldn't like to say ignore the comments below, but this worked for me! :)
02/02/2017
This solution appear not to be working anymore, I tried everything and nothing.
Can you provide the code somehow?
As a test for you to try, you can use this as your opening CSS resets for your email and you might have your fix without sending the code:
http://tabletrtd.com/codelibrary/2015/10/21/opening-css-resets
Thanks, Camille. I will try the resets. Looks like Android 4.4 testing is currently unavailable through Litmus. If this doesn't help, I don't mind sharing the code.
-Patrick
OK, here's my code. No luck w the resets.
Try this:
style="Margin: auto"
Funny. I wish I could force Android to show certain parts of my HTML email to the right. My problem is that it centers it. Crazy stuff.
EDIT: read more about recent Gmail update here:
https://www.emailonacid.com/blog/article/email-development/what-you-need-to-know-about-the-new-gmail-ios-update/
target all Gmail and Inbox versions (Webmail, iOS, Android)
or like this if u want to keep it short
to implement this technique your markup must contain
1) A DOCTYPE.
2) A body with a class name (ie. “body”)
3) An element with a class name (ie. “gmail”)
Targeting Gmail on Android Only (excludes Inbox)
@Jessica Frost
oh yes 320px width on one collum is to much becouse some App's like mailru or Android (not all of them) add extra margin around the newsletter table. They also overwrite the font size like mail.ru does. That way they want to make sure u can read the email properly. to bad that its overwriting your css at some point.
try to reduce it to 300px this should be fine. If your content is pushed to the right (like text) check out your css maybe its the parent element who couse this issue