1

I have drupal 6 with mobile-tools module and idrupal theme for iphones. sometimes my website starts displaying mobile theme (idrupal) for desktop, and the only way to return back to normal theme for desktop is to flush all caches. is there a permanent solution to disallow idrupal theme from being used for desktop?

1

If you are using varnish in front of the your server, then it will completly cache you request, Mobile tools will not be able to determine the useragent is mobile or desktop to redirect the theme.

One of the solution is to determine at varnish level and redirect to a m.domain which always has a mobile theme attached to it.

Refer the following links

  1. http://fangel.github.com/mobile-detection-varnish-drupal/
  2. http://mobiledrupal.com/content/mobile-device-detection-varnish-0
| improve this answer | |
  • Thanks Dinesh,,, but i am not using neither varnish,,,i am just using memcached and i flush it periodically (every one hour) – Alaa Aug 22 '12 at 17:25
  • 1
    @Alaa honestly, that's even worse - with page cache, memcache has no option to tell what should be served, it only knows what got cached. That's why modern themes are trying their best to solve this by CSS and JS, purely on browser's side. – Mołot Jul 17 '13 at 9:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.