Home>Support>Layout Builder in Masthead – new id every time I save changes

Layout Builder in Masthead – new id every time I save changes


I wanted a specific layout in the masthead, and from what I read the best way to do this was to add a Layout Builder widget to the Masthead. I did this and it’s working nicely, apart from one thing.

I have added some Custom CSS relating to the navigation menu, which appears in the Masthead, but every time I edit this widget it gives it a new id. So I have to keep going back into the Custom CSS and updating that every time I make any little change to the widget in the masthead.

For example, it’s called #pg-w606c608300888. I edit the widget and save… then it’s called #pg-w606c57f92199a. I make another edit and save – now it’s called #pg-w606c5a74686cc.

Is there some way to stop this from happening? It’s really annoying – every time I make a change in the widget I have to refresh my frontend page to view it, go into the code to see what it’s now called, go back and edit my Custom CSS to put in the latest id, and finally I can refresh my page in the frontend to check if it looks how I want. If I need to make some little tweak, the whole process begins again! Why does it keep changing the widget id?

Thanks for any input!


This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 1 year, 4 months ago Andrew Misplon Hi, I Work Here

    Hi Jennie

    Thanks for reaching out.

    If you edit a Page Builder row, cell or widget you’ll find an Attributes section on the right. There you can insert an ID or class of your choosing. ID’s change on save for caching reasons, for this reason, they aren’t suitable for Custom CSS. For a short guide on this topic, please, see Post: A Custom CSS Guide to Page Builder Row, Cell & Widget Attributes.

Replies on this thread are closed. Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More