• May 2, 2018
  • Mura Development, Mura.js

Sometimes client needs supersede your development objectives and timelines. This was made very clear recently with a sizable project, one that was a migration of hundreds of “static” pages to Mura CMS. We had agreed on a “freeze” to content on the existing site so that we could finish development and review the Mura CMS version then go live without making sure two instances of the site were up to date.

Well, that went out the window earlier this week and updates were requested to a fair amount of product-related pages that were out of date and outside pressure to update was beginning to mount. My first reaction was “darn” and felt like a setback to reaching our ultimate goal of launching the Mura CMS version as soon as possible. Or so I thought, initially.

Enter Mura.js. I’ve used this “component” of Mura a few times recently to distribute content to off-site properties (landing pages, other entities within an organization, etc.). Basically it is a way to share content and make Mura CMS your central content hub rather than just your destination for your users. There are two options when using Mura.js, one is to pull each individual piece of data individually and assemble on the fly. The other is to request the rendered body (everything but the website template — header, footer, sidebar, etc.).

I decided to try pulling the rendered body from the Mura CMS version of the site into each page that needed to be updated via Mura.js. As expected it was very simple to replicate throughout all pages that needed to be updated after I had my first test case out of the way. This use case was most likely not the intention behind Mura.js but so what, it works and saves me from having worry about keeping two instances updated and the client from having to review two instances.

Since I already have a plug-in setup to redirect legacy links (for search engine results) I could leave the existing links intact for the time being and have them work on both sites. At the time of loading the page content onto the current production version of the site I do a quick find/replace for the image references so they match up as well.

Once again, Mura (and a tiny bit of ingenuity) made something very simple that could have been very frustrating and wrought with penitential for making mistakes.

Interested In Working Together?

Fill out the form below and I’ll be in touch within one business day.