ColdMVC

Directory Structure

Since ColdMVC is a convention-based framework, it's important that applications follow a similar directory structure in order to take advantage of the framework's conventions. A typical ColdMVC directory structure looks like the following:

app/
    controllers/
        LayoutController.cfc
    helpers/
    layouts/
        index.cfm
    model/
    tags/
    views/
config/
    coldspring.xml
    config.ini
    environment.txt
    hibernate.hbmxml
    plugins.cfm
    routes.cfm
public/
    css/
    images/
    js/
    index.cfm
Application.cfc

Here's a brief description of the various files and folders.

/app/
Contains the majority of your ColdMVC application (.cfm and .cfc files).
/app/controllers/
Contains your controllers.
/app/controllers/LayoutController.cfc
Handles putting data into layouts.
/app/helpers/
Contains your helpers.
/app/layouts/
Contains your layouts.
/app/layouts/index.cfm
The default layout.
/app/model/
Your domain model. Contains any persistent entities and services.
/app/tags/
Contains your custom tags.
/app/views/
Contains your views.
/config/
Contains your configuration files.
/config/coldspring.xml
Contains any custom ColdSpring bean definitions.
/config/config.ini
Contains your configuration settings.
/config/environment.txt
Contains the name of your current environment, which is used to determine your settings.
/config/hibernate.hbmxml
Contains your Hibernate mappings.
/config/plugins.cfm
Defines any plugins used by your application.
/config/routes.cfm
Defines any custom routes for your application.
/public/
Your application's web root.
/public/css/
Contains any CSS files.
/public/images/
Contains any images.
/public/js/
Contains any JavaScript files.
/public/index.cfm
Your application's front-controller index page. All requests are routed through this file.
Application.cfc
Your project's application page. Typically just extends coldmvc.Application.