Design v2

The new community website design is just about complete. I’ve moved along onto more troubling things as finishing the CMS.

It’s really interesting when you do something right… things seem to… work! The best idea we’ve had was to properly design a CMS and make it modular. I can’t even begin to explain how its helped the process. Instead of having shit loads of code in a single file, I’m able to break them apart and organize the functions.

The way it works is pretty simple too. First you create your CMS’s main class, and when the page is called it creates an instance of it… lets say $CMS.

The CMS loads all its modules into an array, $CMS->Modules[]. From there you can have stuff like $CMS->Modules[News] or $CMS->Modules[Files] or anything. Each one of the keys are an instance of a class created from the modules.

Then when we’re writing the front page, we can just add a line of code somewhere in the HTML like $CMS->Modules[News]->DisplayNews(). Everything is handled in the module code and doesn’t need to clutter up the HTML of the front page. WHRY is this so helpful? Simple answer is simple: If we need to move any HTML around, or tweak the way the front page looks, we don’t have 120 lines of PHP code jammed in the ass of it all.

Progress is good, but I think I have to take a break for a while and start moving the files over to the new webhost because the old webhost is starting ot take a shit.