[Support request] How to show or hide GP widget on specific pages?

Home Forums Support [Support request] How to show or hide GP widget on specific pages?

Home Forums Support How to show or hide GP widget on specific pages?

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #372095
    Johannes

    Hi,

    How to show or hide GP widget on specific pages? I suppose I can add a custom CSS class to it and the use some CSS?

    -Johannes

    #372109
    Leo
    Staff
    Customer Support

    Hi there,

    For sidebar widgets? If so I would recommend this handy plugin:
    https://en-ca.wordpress.org/plugins/content-aware-sidebars/

    If not then we need to use some CSS. Can you link me to the page and let me know which widgets you would like to hide?

    #372433
    Johannes

    Hi, let say I want to have the search field ( in header ) only on specific pages.

    http://www.johannesoedegaard.com/generatepresstest/

    – Johannes

    #372709
    Leo
    Staff
    Customer Support

    Ok so use Tom’s Simple CSS plugin: https://docs.generatepress.com/article/adding-css/#simple-css

    and add this CSS in the CSS meta box on the pages you don’t want the search field:

    .header-widget {
        display: none;
    }

    Index pages (blog, archive) need to be handle differently so let me know if you want to hide it on them too.

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