[PHP][OOP][MySQLi] Content Management System

Status
Not open for further replies.

AaidenX

Member
Jun 30, 2012
261
29
Greetings!
I'm Hassan Althaf and I am a Back-End developer. I love to code Applications. So, I was bored, and decided to code a CMS. Please do not mis-understand it as a Habbo Retro CMS, it has nothing to do with that. This is basically a easy-to-integrate CMS for websites to easily maintain their site with SEO friendly URLs. I'm planning to keep this an OpenSource Project, I'll be setting up a GitHub for this soon.

Development Build: v 1.0.0
Snippets:
PHP:
<?php
namespace CMS\Core\Templating;
class TemplateController {
    private $templateMapper;

    public function __construct(TemplateMapper $templateMapper) {
        $this->templateMapper = $templateMapper;
    }

    public function handlePageLoad($page_name) {
        if($templateMapper->verifyExistance($page_name)) {
            $templateMapper->loadPage($page_name);
        }
    }
}
PHP:
<?php
/**
 * Please do not edit anything here. Everything other than the database details can be editted in the Administration Panel.
 */
$configuration = array (
    /**
    * @var Array $configuration['database'];
    * Stores database information.
    */
    'database' => array (
        'host'     => 'localhost',
        'username' => 'root',
        'password' => 'php123',
        'database' => 'cms'
    ),
    /**
    * @var Array $configuration['errors'];
    * This is where you setup Error Logging System.
    * If you want to enable an error logger, which logs all sorts of errors, then set enable_error_log to 1, else 0.
    * If you want the error log to save in a .txt file, then set error_log_method to 'local'
    * If you want the error log to save in a Database, then set error_log_method to 'database'
    * If you are currently a Developer, and this is hosted privately, set show_errors to 1 so that you can see all errors.
    * If you are currently hosting this system publically, set show_errors to 0 to hide confidential information about your website.
    */
    'errors' => array (
        'enable_error_logs' => '1',
        'error_log_method' => 'database',
        'show_errors' => '1'
    )
);

Features Planned:
- Templating System
- Theme System
- Error Logger System
- Blog System
- Forum System
- An All Seeing Eye/Administration Panel for Admins to manage the Website.

If you have any questions/further inquiries, add aaidenx on Skype or You may also shoot me a PM or Reply here.
 

Zodiak

recovering crack addict
Nov 18, 2011
453
417
Good luck but for future reference remember this:
You're using un-needed functions for grabbing things by the looks of it, which reduces page speed.
Code:
if($templateMapper->verifyExistance($page_name)) {
            $templateMapper->loadPage($page_name);
        }
I assume "verifyExistance" contains if(file_exists("")). So you could just use that in the current functions and I assume loadPage is obviously echo'ing the file contents. Which you can also use in that one function.
 

AaidenX

Member
Jun 30, 2012
261
29
Moderator lock thread. I have postponed the development of this project until the end of my Exams.
 

Sysode

Front-End Developer
Dec 11, 2012
1,673
848
Thread locked upon request. Feel free to PM a moderator once you are ready to start this back up.
 
Status
Not open for further replies.

Users who are viewing this thread

Top