Global Blocks for Cornerstone

Michael BournePosted:

Have you ever wished you could create a section in Cornerstone and re-use it on multiple pages? How about doing that, and being able to edit them all in one shot? Well, wish no more. Introducing the Global Blocks for Cornerstone, brought you by X Theme Tips.

Oh, it’s also free for life.

This is a lightweight, easy to use plugin that allows you to create a “global block”, which is our way of saying a template that can be created in one location and reused anywhere. On top of that, once you edit the global block, everywhere it has been used will be updated as well.

How do I get it?

Your first step will be to download the Global Blocks for Cornerstone plugin directly off the WordPress repo.

global blocks for cornerstone

Global Blocks for Cornerstone

Once installed, you will see a new entry in your wp-admin navigation called “Global Blocks”. This is a Custom Post Type created specifically for this plugin. It will be Cornerstone enabled by default.

Adding a Global Block.

Click Global Blocks > Add New. When adding a new block, you are free to use the default editor or Cornerstone. The default template when using X theme will be “Blank – No Container, No Header, No Footer”. This will give you a blank palette in which to create your block. Here you can make any layout imaginable in Cornerstone, with all available elements. What’s more is any custom CSS or JS you enter in Cornerstone will be printed (inline) with the Global Block where ever it is used.

Using the Global Block in a page.

After creating your block, open Cornerstone on the page you want to use ue it and simply drag the custom element where you want it. Select your chosen block from the drop down and it will appear! My advice here is to plan ahead for margins and padding. Most users will want to set the receiving section to 0 padding, and disable column container on the row. This way the Global Block will fill the entire section.

Global Blocks element

Custom Cornerstone Element

And that’s it! We are currently at version 1.0.0 and are open to any ideas for future advancements or new plugins. Roy and I are both accomplished WordPress developers, and we are eager to help the Themeco ecosystem with plugins such as this.

Have a question or a comment about this article? Click here!
About the Author

Michael Bourne


Hey, I'm Michael, and I've been making websites since the mid 90s! These days I focus on Wordpress and would call myself quite handy in PHP, JS, and CSS. Outside of coding and web design, I'm quite fond of craft beer and backpacking around the world.

Share this Tip!