I'm loving the new Bedford template on Squarespace (you're looking at it) the only thing I felt was missing was the gallery pages don't have the banner and title text.
After a quick chat with support (absurdly eager to help) I was told the gallery lack of banner goodness was by design so it didn't clash with the gallery content itself.
That makes sense on reflection, but the banner text itself would still be cool to have. This post is my solution v1 and I'm sharing for it everyone else to use.
It works as follows:
- the page loads with the "Header Flag" called injectMe
- the page renders and the footer code executes
- does the page have the meta tag injectMe?
- if yes, get the page description from the header (Squarespace adds this by default, even if the page doesn't use it)
- grab and remove the page content
- join the page description with the page content and insert into the page
More details can be found on github, including the code. Github is really just a simple web site for sharing code, you don't have to sign up to see the solution. I expect the code to refine over time, and you're more than welcome to take the code and use it in any way you see fit, including commercially.
This will be first hack I publish, I already have an idea for a totally pointless but fun challenge hack.