Support » Theme: Chosen Gamer » Hide iframe in mobile

  • Resolved jempanada

    (@jempanada)


    Hi there,

    I had a bit of genius idea to embed my Twitch channel to the “After Main Content” widget. However, I want to hide it when my blog is viewed from mobile. Otherwise, it gets loaded and cut off when viewed.

    With the new WordPress editor, everything is a bit different now and now it’s a `<figure></figure>’ instead of the usual embed code. Is this possible to hide this? Or will this break the website?

    I’ve linked a post link and here’s my homepage link: https://jempanada.com/

    Thanks in advanced.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hello jempanada,

    Add below css code into your current active child theme’s style.css file or you can add additional css option in theme customizer.

    @media (max-width: 480px) {
      section#custom_html-5 {
        display: none;
      }
    }

    Hope this will helps you.

    Thanks.

    Theme Author Ben Sibley

    (@bensibley)

    Hey,

    You might want to consider using the Widget Options plugin as well. It includes an option to show/hide any widget on mobile devices. CSS will hide the widget, but it may not prevent it from still loading the content which can slow down the site. By using Widget Options, the widget won’t be output at all, so the mobile site won’t load any slower.

    jempanada

    (@jempanada)

    Appreciate it, Ben! That did the trick.

    Theme Author Ben Sibley

    (@bensibley)

    Sure thing, glad I could help!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Hide iframe in mobile’ is closed to new replies.