WP Mobile Detect
Desktop sometimes shows Mobile (3 posts)

  1. SloBros
    Posted 2 years ago #

    In Chrome with browser cache enabled and using w3tc total cache on the site, the mobile menu sometimes shows after visiting the page for the first time, then shows the desktop correctly after refreshing.

    After clearing the browser cache, it happens again later.

    It might be a crazy thought, but could it be due to someone visiting the mobile site, then w3tc caching the page, and then showing that cached mobile page to someone else who visits on the desktop?


  2. Andrew W
    Posted 2 years ago #

    Hi SloBros -- that's basically what's happening to me, best I can tell.

    In my case, I need different versions of a logo to appear on desktops/tablets vs. phones. I use WP Mobile Detect to do some "if" statements in header.php to determine which version of the logo to serve.

    But then caching gets involved: whichever version gets cached first is the version that gets served to all devices until the cache expires.

    Did you end up figuring out a workaround?

  3. MaximumFish
    Posted 1 year ago #

    I'd also like to know if a workaround or fix was ever found for this. I'd like to start using some sort of cache but a lot of my pages rely on showing different content to different devices.

    Anybody have any luck with it?

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP Mobile Detect
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic