There are many ways to do this with ColdFusion.
Application.cfc is executed for each request and has two methods ( onRequestStart and onRequestEnd ) that can be used to add / add content to the main script on the page.
It's also worth noting that it is possible to extend / inherit your Application.cfc, allowing a more complex set of RequestStart / End events. More details here and here .
Custom tags allow you to create a tag that you can wrap around each template to apply the / etc layout. It also allows the / etc attributes to define generic but changing text.
For example:
<cf_page PageTitle="My Page"> [main page content] </cf_page>
And inside the user tag (page.cfm) you have:
<cfif ThisTag.ExecutionMode EQ 'start'> <cfparam name="Attributes.PageTitle" default=""/> <cfcontent reset/><cfoutput><!DOCTYPE html> <html> <head> <title>My Website - #Attributes.PageTitle</title> [styles and scripts and stuff] </head> <body> <div id="heading"> <img src="my_website_logo.png" alt="My Website"/> </div> <ul id="mainmenu" class="nav"> [menu] </ul> <h1>#Attribute.PageTitle#</h1> </cfoutput> <cfelse> <cfoutput> <div id="footer"> [footer] </div> </body></html></cfoutput> </cfif>
And, of course, you can create several custom tags or one tag that works differently depending on the specified attributes.
Henry already mentioned MVC Frameworks , but you do not need to do MVC to use the functionality of templates / layouts.
Fusebox can run MVC, but it doesnโt require you to do this, and in any case, FB ContentVariables is a good tool for implementing modular content - unless your lead developer can justify your dislike of Fusebox (and suggest an alternative that suits your project!), There is absolutely no reason not to go for it - this is a mature and well-known structure, easy to use, many developers, etc.
However, if Fusebox is really not an option, look at the list of Charlie Areart frameworks - this page as a whole is a huge list of tools that are worth paying attention to.
Anyway, this should give you enough things to consider at the moment ...