• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Detect phone / tablet / desktop : Media queries or Server side detection ?

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › Detect phone / tablet / desktop : Media queries or Server side detection ?

This topic is: not resolved

Tagged: media queries, mobile

  • This topic has 3 replies, 2 voices, and was last updated 11 years, 6 months ago by Brad Dalton.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • May 28, 2014 at 7:19 pm #107222
    Loudness
    Member

    Is there a way to detect if a user is using a tablet, a phone or a desktop ?

    I know I can use media queries, but here's the problem : some phone now have the same resolution as tablet, but only have half the screen size. (more pixel density). I want a particular notification bar to be shown on the right side on desktop & tablet, but this same bar should be at the bottom on phone since it would take too much space on the side on a phone.

    What would be the best ? Server side detection ? A plugin such as WP Mobile Detect ? I saw a couple article stating media queries were better than server side detection (not sure why), but then I have the problem stated above.... : Some device have the same resolution, but different screen size.

    Any suggestion would be appreciated.

    May 29, 2014 at 1:17 am #107250
    Brad Dalton
    Participant

    You can use mobile conditional tags from a plugin like Mobble or write your own. http://clicknathan.com/web-design/wordpress-mobile-conditional-statement/


    Tutorials for StudioPress Themes.

    May 29, 2014 at 9:43 pm #107411
    Loudness
    Member

    is it possible to load a plugin conditionally using the above plugin ? (or Wp mobile detect) ?

    So this way I could install 2 different plugin : 1 for the pull out notification for desktop + tablet & another plugin for the notification bar at the bottom & just load the one required by the user based on the device they use ?

    May 29, 2014 at 11:03 pm #107415
    Brad Dalton
    Participant

    I would ask the plugin Developers this question as they are the best people to ask.


    Tutorials for StudioPress Themes.

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘General Discussion’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2025 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble