[Resolved] Remove sidebar widget from mobile (but not from desktop)

Home Forums Support [Resolved] Remove sidebar widget from mobile (but not from desktop)

Home Forums Support Remove sidebar widget from mobile (but not from desktop)

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #746290
    Evan

    Hi again!

    Thanks as always for your help. I had a question regarding sidebars on mobile vs desktop.

    I have a 4-widget right sidebar on http://www.evantarver.com but I only want three of those four widgets to display on mobile.

    Is there a way to remove a sidebar widget from displaying on mobile while allowing it to display on desktop?

    Thanks!

    – Evan

    #746330
    Leo
    Staff
    Customer Support

    Hi Evan,

    I’m on the About page and only see 3 sidebar widgets currently.

    Can you add them all in and let me know which one you want to remove on mobile?

    #746351
    Evan

    Hi, thanks for the reply –

    That’s a plugin overriding the default sidebar for the about page specifically, which I want to have three widgets on both desktop and mobile, removing the top image from the default sidebar.

    If you look at any of the other pages on desktop, there are four widgets in the default sidebar: an image, categories, newsletter sign up, and another image.

    I’d like to remove the first image when displaying on mobile for all sidebars across all posts and pages.

    Is that possible to do?

    – Evan

    #746361
    Leo
    Staff
    Customer Support

    Try this CSS:

    @media (max-width: 768px) {
        .sidebar #widget_sp_image-6 {
            display: none;
        }
    }

    Adding CSS: https://docs.generatepress.com/article/adding-css/

    Let me know 🙂

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.