[Resolved] Override Global header elements

Home Forums Support [Resolved] Override Global header elements

Home Forums Support Override Global header elements

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #392400
    Svetoslav

    Hi Tom,

    I have a scenario where I can set a global header for all pages but would like to override the background image for each individual page. I’m pretty comfortable coding something myself but wanted to check incase you have already thought of something :-).

    Thanks in advance.

    #392401
    Svetoslav

    I am using GP 1.4.3

    #392525
    Leo
    Staff
    Customer Support

    Hi there,

    Are you referring to the header background image or page header?

    Let me know.

    #392526
    Svetoslav

    Ho Leo,

    I am referring to the header background image.

    Thanks

    #392531
    Leo
    Staff
    Customer Support

    If you use Tom’s Simple CSS plugin, it gives a CSS metabox on each page, then you can overwrite the header background image by doing this:

    .site-header {
        background-image: url(http://page-specific-image);
    }

    https://docs.generatepress.com/article/adding-css/#simple-css

    Or else you find the page ID and do this:

    .page-id-xx .site-header {
        background-image: url(http://page-specific-image);
    }
    #392815
    Svetoslav

    Thx Leo. That helps allot.

    #392942
    Leo
    Staff
    Customer Support

    No problem!

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