PHP Classes

File: docs/overview/ProjectTree.md

Recommend this page to a friend!
  Classes of Slawomir Kaleta   Dframe Framework   docs/overview/ProjectTree.md   Download  
File: docs/overview/ProjectTree.md
Role: Auxiliary data
Content type: text/markdown
Description: Auxiliary data
Class: Dframe Framework
Modular MVC based PHP Web framework
Author: By
Last change: Update of docs/overview/ProjectTree.md
Date: 3 years ago
Size: 944 bytes
 

Contents

Class file image Download

How to create correct Tree folders and files

If you have many many methods in one controller ex. articles you should build folder according on the modules

You do not have to have big applicaiton to create tree. Example in articles modules you should have folder tree looks like

-app
    -Controller
        -Articles // Controller folder
            -Content.php
            -Category.php
        -Controller.php
        
    -Model
        -Articles // Model folder
            -Content.php
            -Category.php
            -Commnets.php

For comments you don't have to Controller becouse comments will be under article so you should load

$this->loadModel('Articles/Commnets');

in your Articles/Content

Router

will be looks this

index.php?taks=articles,content&action=index
index.php?taks=articles,category&action=index

or Friendly Url

articles,content/index
articles,category/index