Forum Moderators: Robert Charlton & goodroi
Google Emailing Non-Mobile Friendly Sites
What's worrying by the message - at least the way I interpret it - is that Google appears to be threatening to rank what it regards to be "mobile unfriendly" pages differently on phones than it ranks them on PCs.
my only problem with it is that the mobile test seems to paint everything with the same brush. a site that looks and works okay on one size of phone (a bigger phone) might not be as pleasant on a smaller phone, but they still mark it as mobile-unfriendly. the screen size that the test uses is very small indeed (is it 320px?).
<link rel="stylesheet" type="text/css" media="only screen and (max-device-width: 480px)" href="mobile-friendly.css" />
Can anyone tell me whether adding mobile stylesheets in the following way to the html header is enough to pass their viewport test?
<meta name="viewport" content="width=device-width, initial-scale=1"> the mobile will just display the site at whatever width it is normally
Are these emails being sent to mainly ecommerce sites and/or informational sites, as well?
AddOutputFilterByType DEFLATE text/css text/javascript
Squashing a 728 down into 320 pixels by sizing in percentages makes it too tiny to readIt may appear that way on some device emulators, because they can't all emulate device pixels. Really it is not seen at 320 wide, it does not use "desktop" pixels but device pixels so a 728 banner viewed 320 on a desktop is unreadable, but not on a device with a 320 px screen (ratio 2 to 1) using 640 device pixels. It reads just fine.
Squashing a 728 down into 320 pixels
but not on a device with a 320 px screen (ratio 2 to 1) using 640 device pixels. It reads just fine.
i can confirm that it's not enough. what finally fixed it for me was to reduce everything below the width of 320px. if anything is sticking out beyond that then it seems to fail... unless you do this:
<meta name="viewport" content="width=device-width, initial-scale=1">
that should pass it, but unfortunately the mobile will just display the site at whatever width it is normally, even if it is a lot wider than the screen -- meaning the user will have to do loads of horizontal scrolling
Are these emails being sent to mainly ecommerce sites and/or informational sites, as well?
What I need to do is find a way to detect the screen size and deliver smaller images. I know I could use css to do that, but I'm looking for a server-side way to do it.
just leave off the dimensions in your html code and size them with CSS
But that's not a really happy tradeoff, because it adds to rendering time.
"Make the picture such-and-such size unless such-and-such circumstances arise."