Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By DD_IT on
I want to disable mobile device detection and force only the full desktop view of my Drupal 7 site. Is there a simple way to do this?
Comments
What theme are you using?
What theme are you using? Core does not detect mobile devices.
Theme being used
I'm using Starfish Responsive Theme. Sorry, I'm such a noob to Drupal. Guess I'll have to disable this in the theme's code as there doesn't seem to be a setting for it. Thanks for responding.
=-=
That's the whole point of a responsive theme. Rather than hacking the theme apart, I suggest a non responsive theme be used.
Responsive designs don't have
Responsive designs don't have detection, they respond based on the width of the browser (hence the name 'responsive' design). If you resize your browser to the same width as a mobile, you'll see the same design as a mobile. So there is no mobile detection.
To fix this, you'd have to remove all the media queries from the CSS. And this would require that the default non-media query CSS is set for browser size, which often it's not (I myself build for mobile, and add media queries for larger widths).
You are probably better off just finding a non-responsive theme. Though I don't understand why you would want to downgrade functionality.
Follow up
Thanks for the replies. I knew that responsive themes changed width based on browser width. It does in my PCs' & laptop's browsers. However on my Android (Galaxy Note 4) phone it will only display the narrowest of the theme's 4 widths. This is regardless of the phone's orientation.