google mobile friendly test - not working for nop?

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
8 yıl önce
Here is a response a colleague got on a Google webmaster forum maybe someone who understands user agents in nopCommerce can help:

Hmmmm.... slightly tricky one...

So the site is dynamically served and written in ASP - and it's doing mobile redirections based on user agent from the server side? Right?

Mobile Friendly Test fails, because Googlebot is not seeing a mobile redirection:
https://www.google.com/webmasters/tools/mobile-friendly/?url=http%3A%2F%2Fwww.nhproequip.com%2F

However, PageSpeed Insights (which doesn't use Googlebot) correctly sees a mobile redirection:
https://developers.google.com/speed/pagespeed/insights/?utm_source=MFT&utm_campaign=MFT&utm_medium=incoming-link&priorityGroup=USABILITY&url=http%3A%2F%2Fwww.nhproequip.com%2F

So are you doing anything special for Googlebot (cloaking) or testing for Googlebot with the wrong user agent (e.g. the old Googlebot-mobile user agent)?

I can get the mobile site to come up in Firefox spoofing an iPhone, but I cannot get it to come up in Chrome spoofing any mobile user agent at all. That is a bit weird.

So I'd hazard a guess that there is some issue with user-agent or mobile device detection... or the way you are dynamically building the pages is causing an issue.

1) If you are dynamically serving, Google recommends you send a Vary: User-agent http header to avoid confusing Googlebot.

2) It looks to me like you may be dynamically building CSS (and/or JS??) as well as HTML (for example, styles.css builds to different sizes for a mobile and desktop user agent) and Google has flagged this up as a problem - something to avoid - several times recently:
https://plus.google.com/+PierreFar/posts/1KBKo3YeoJT

However, neither (1) nor (2) explains (to me) why I can't get the mobile site to load properly in Chrome's Mobile Emulator, so there may be more than one issue here.

(Another complication is that (I think) you seem to be setting a cookie with device or user-agent information in it.... so cookies have to be cleared out if you're doing spoof tests on the desktop. May be wrong about this but it wouldn't work till I cleared cookies.)

Sorry I can't be more concrete than that... but I think it's that sort of issue.
8 yıl önce
Did you try my suggestion?
8 yıl önce
I'm not sure what you are suggesting. If I run the analysis with the url you suggested nothing changes. Is this a solution you applied to a nopCommerce site experiencing this problem or are you making a general suggestion of something to try?
8 yıl önce
Hi Nick4501

I've checked your suggestion "Use Google's test to browse the URL which explicitly sets it to mobile mode (e.g [domain]/changedevice/false)".

Doesn't work. Still the same.
8 yıl önce
I tried device emulation on chrome and it finds the mobile theme correctly. You do have to select a device from the dropdown so it can send a different user agent and get the mobile theme, the default view just shows a sized down window without any mobile user agents sent to the server.
8 yıl önce
Sorry guys, you're right - the test is now failing again for me so my fix must have just been a coincidence.

Please could we have a comment from the NOP guys about this?
8 yıl önce
These guys are talking about the issue as well - as i suspected, google is not sending the mobile googleot to crawl teh site, so anything that changes layout or design etc based on the user agent will fail (but responsive sites should work). they need to fix this. http://www.searchenginejournal.com/flawed-google-mobile-usability-test-results/127623/
8 yıl önce
Wow, quite an article.  Maybe Google will fix it but I think implementing a responsive theme may be faster. I like this line: Google Shoots First, Sometimes Never Asks Questions
8 yıl önce
The problem I have is possibly due to google/yahoo or other search engine incorrectly accessing the /viewswitcher page which force the server sending the desktop version of my website. Blocking the viewswitcher page on ActionResult RobotsTextFile fixed my problem.

And also you would need to manually change the DontUseMobileVersion attribute from True to False in the [GenericAttribute] table for bot in the database
6 yıl önce
we're still running an older version nop and this is still a problem, google is showing the "this site is not mobile friendly" message in their results. guess we'll have to change out to a responsive theme/new site to get this working.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.