Content management systems are becoming very popular, but what if you took it a step further than that? That’s exactly what I plan to show you how to do in this series of articles. I’m going to explain how to build a site engine. A site engine is a core code base and database that can run multiple sites that are completely different while all running in unison, using all the same code, yet separate from each other.
A while back, I created a website with object oriented PHP. Then I thought to myself, "Wow, this site works great. It's got low parse times, and its structure is solid." At that very point I thought it would be great if I made a centralized code base and database that would run multiple websites. I decided that it would have to have a template system because who wants all their websites to look the same. Also, it would need a plug-in system so that each site had its own type of functionality, after all what would be the point of different sites if they all did the exact same things. Authentication would be also need to be implemented, due to the fact that the administrator would probably want a secure way to administer the sites. Each site would need its own content system, which would prove to be the most confusing part of the entire project, because I wanted it to all work off the same code base and the same database. However, I found a seemingly logical solution that may confuse some people, but I think I can explain it fairly well.
In this first article, I'm mostly going to outline the site engine. I will go over what it does, how it does it, and why it does what it does. In the following articles in the series, I'll get into the actual technical aspect of all the coding. The articles are as follows:
Article1: General Outline and Preparation
Article2: Plug-in and Module systems and General Functions
Article3: Authentication and Block Systems
Article4: Template and Loading Systems
Article5: Building a site and Administration samples