开发者

MVC internal working PHP

I ha开发者_JS百科ve basically the following folder structure:

Framework_Folder
    |__application
    |     |_Models
    |     |_views
    |     |_controllers
    |
    |__config
    |__core
    |     |
    |     |_model.php
    |     |_controller.php
    |     |_bootstrap.php
    |     |_security.php
    |
    |__index.php
    |__.htaccess

I do this way: I redirect all http request to index.php using .htaccess Index.php set up Absolute paths and loads bootstrap.php bootstrap.php loads security (which turns of global register, magic quotes et al) and loads the required controller

I wonder if theoreticall there is something Iam missing or I'm doing wrong before I put to test this design. Also any suggestion of anything to add or remove is appreciated.


I ended up using same structure with little modification to accomodate templates. Else, it is perfect structure, at least for me!

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜