[Resolved] Linking to different pages depending on screen size

Home Forums Support [Resolved] Linking to different pages depending on screen size

Home Forums Support Linking to different pages depending on screen size

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #149808
    BeeLady11

    Hi

    Firstly let me say, why didn’t I discover GP and the lovely addons earlier?! They really have helped me no end ๐Ÿ™‚

    I have a link on my GP site’s homepage (in a section) – I would like it to link to smallpage.php for mobiles and bigpage.php for tabs/PC’s. I guess I’ll need to use media queries somehow, but I want the destination page loaded when the user clicks the link, not served up on page load.

    (It’s actually 2 different versions of a form; one is quite complicated and the other is compact).

    Hope that’s not too garbled!

    Thanks.

    #149821
    Tom
    Lead Developer
    Lead Developer

    You could try adding two links to the page.

    For example:

    <a href="smallpage.php" class="hide-on-desktop">Link to mobile</a>
    <a href="bigpage.php" class="hide-on-mobile">Link to desktop</a>

    The classes should display that link if it’s on mobile/desktop and hide the other one.

    Let me know ๐Ÿ™‚

    • This reply was modified 8 years, 2 months ago by Tom.
Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.