MV – simple PHP framework with an Admin Panel

  • Website Content Management through CMF
  • Object-oriented approach and MVC principles
  • Auto-generation of Admin Panel
  • ORM and ready-to-use functional blocks (sorting, filtering, etc.)
  • Visual editor, images bulk uploading and much more

Quick Review

Working process starts with creation of the Model - PHP class to manage SQL table. Fields of the model have different data types based on principles of web development.

class Articles extends Model
    protected $name = "Articles";
    protected $model_elements = array(
        array("Activation", "bool", "active", array("on_create" => true)),
        array("Name", "char", "name", array("required" => true)),
        array("Date", "date", "date", array("required" => true)),
        array("Content", "text", "content", array("rich_text" => true)),
        array("Images", "multi_images", "images")

After creating the class and SQL table an interface is becoming available in Admin panel to create, edit and delete records, and also you will get a sidebar with filters appeared to help you search required records on all fields.

Binding of template to URL is accomplished by Routing.

"article/*/" => "view-article.php"

To show model data on the webpage a template file is being created.

<div id="inner">
    <p class="date"><? echo I18n :: formatDate($article -> date); ?></p>
    <h1><? echo $article -> name; ?></h1>
    <div class="text">
        <? echo $article -> content; ?>
    <div class="gallery">
        <? echo $mv -> articles -> displayGallery($article -> images); ?>

In MV framework templates generation is being accomplished by PHP itself to guarantee high speed of template process and page generation in total. That is in templates that methods of models are being called, and also fields of databases are extracted with the help of Record object, that is responsible for ORM process organization.

Main idea of MV is to provide a simplified and faster way to create websites and web applications with the help of built-in CMF that allows to manage content with Admin Panel.