One Container to rule them all, One Container to find them,
One Container to bring them all and in the templates bind them
In the CMS of OpenTextRedDot where the Content lies
Ok, first up – a warning and some history. This is a long post that I have been working on, off and on, since the end of last year. Don´t be scared, most of the time and the bulk of the post is in the examples – which I have only recently had access to a suitable server to build and test. With a bit of luck, future posts will be a lot more compact – as this article lays the context for a lot of other posts I have been meaning to write – both in providing what I hope you will find to be a ¨real¨ example site, as well as the base template ¨pattern¨ that a lot of my solutions build upon.
So this post is a story about base templates. What I´ve seen, what I use and what I consider to be the advantages and disadvantages of both. Interestingly though, this post came about not from developing new projects, but from refactoring existing ones – and therefore I hope brings value regardless of where you are currently at. What I am about to show you comes squarely under the category of “things I wish I had known before my first project”.
This post is split into three sections. The first introduces you to our example project with what I consider to be the ¨easiest to implement, hardest to maintain¨ method of base template creation – ¨copy and paste¨. The second section takes our example project and converts it to what seems to be the most common method – ¨header and footer¨. The final section will lead you through the steps to refactor any project to my preferred method – ¨include container¨. Along the way there are sure to be a few interesting tips as well.
On a final note before we begin proper – while the example project works and hopefully will help you in understanding the advantages and disadvantages of the various methods discussed – it is not complete (for one, it doesn´t contain any red dots) nor optimal (for example, we have a lot more work to do towards localisation). Feel free to note in the comments any issues you would like to see addressed in future articles (or write them yourself!) – but try to keep the implementation discussions to the topic of this article – thanks! Oh, and probably one thing this example unfortunately doesn´t lend itself well to is navigation manager examples – but we will cross that bridge when we come to it.
No related posts.