Yii Framework directory structure detailed analysis Instructions _php tutorial

Source: Internet
Author: User
Tags php framework website server smarty template yii

Yii Framework directory structure detailed analysis description


This article lists in detail the directory structure and directory instructions for developing a project with Yii, and the friends who are learning about the PHP framework Yii can collect and look at it.

/****yii Core Source directory structure Description ****/The |--framework Framework Core library |--base the underlying class library folder, which contains CApplication (application class, responsible for global user request processing, which manages the set of application components that will provide specific functionality to the entire application); Ccomponent (Component class, The file contains the base class for component-based and event-driven programming, starting with version 1.1.0, a property of a behavior (or its public member variable or a property defined by its getter and/or setter methods) that can be called by the component's access); Cbehavior (Behavior class, Primarily responsible for declaring events and corresponding event handlers, attaching object behavior to components, and so on, CModel (model classes, base classes for all data models), Cmodule (the base class for modules and applications, primarily for application components and submodules), etc. |--caching All caching methods, including Memcache cache, APC cache, data cache, Cdummycache virtual cache, Ceacceleratorcache cache, and many other caching methods |--CLI Yii Project Generation script |--collections Constructs the traditional OO language data storage unit in the PHP language. Such as: queue, stack, hash table, etc. |--console yii console |--db database operation class |--gii Yii code generator (scaffolding), can be generated including models, controllers, views and other code |--i18n YII Multi-language, provides the various languages of the local Data, information, document translation services, localized date and time formats, and digital |--logging log components, YII provides flexible and extensible logging capabilities. Message records can be classified according to log levels and information categories. Apply hierarchy and Category filters to further select messages routed to different destinations such as files, emails, browser windows, etc. |--messages tips for multilingual     |--test Yii provides testing, including unit testing and functional testing     |--utils provides common formatting methods     |-- Validators offers a variety of verification methods     |--vendors This folder includes a third-party database used by the YII framework     |--VIEWS provides a multilingual view of yii errors, logs, and configuration files     |--web Yii All methods of developing applications         |---Actions controller operation         |---Auth rights recognition class, Includes identity authentication, access control filtering, access control for basic roles         |---Filters filter that can be configured to execute before or after the controller action is executed. For example, an access control filter is executed to ensure that the user is authenticated before the requested action is performed; the performance filter can be used to measure the time spent by the controller execution         |---form form generation method         |---Helpers view helper, including Google AJAX API, create Html,json,javascript related features         |---js JS library  & nbsp       |---renderers view rendering component         |---Services encapsulates soapserver and provides a WSDL-based Web service   & nbsp     |---Widgets parts         |---carraydataprovider.php can configure the sorting and paging properties to customize the behavior of sorting and paging         |---cactivedataprovider.php ActiveRecord method         |---The ccontroller.php controller approach, primarily responsible for reconciling the interaction between the model and the view |--blog_phpernote.com/    |--index.php                 WEB Application entry script file &nbsp ;   |--assets/                  includes open resource files     |--css/  &NB Sp                   includes CSS files     |--images/      &NBSP ;           include image files     |--themes/                  include app themes     |--protected/                include protected application files     | -YIIC                      YIIC command line script     |--yiic.bat &nbs P                windows YIIC command line script     |--commands/    &NBSP ;           includes custom ' YIIC ' commands         |--shell/        &NBSP ;   &NBsp   includes custom ' yiic Shell ' command     |--components/              includes reusable user components         |--mainmenu.php           ' MainMenu ' pendant class         |--ident ity.php           the ' Identity ' category for authentication         |--views/      &NB Sp         view file with pendant             |--mainmenu.php       ' Mainmen U ' pendant view file     |--config/                  include config file     &nbs P   |--console.php           Console app configuration         |--main.php     &NBS P        web application configuration     |--controllers/              include controller class files         |--sitecontroller.php     Default controller class files         |--data/      &nbsp             includes sample database             |--schema.mysql.sql   &NBS P   Example MySQL database             |--schema.sqlite.sql     Example SQLite database             |--testdrive.db           Example SQLite database file     |--extensions/               includes third-party extensions     |--messages/          &NBS P     translated message     |--models/                  include model class file &nbs P       |--loginform.php         ' Login ' action form model         |--contactfor m.php       ' Contact ' action form model     |--runtime/            &NB Sp   includes temporary generated file     |--views/                    includes controller's view and layout files & nbsp       |--layouts/              include layout view files         &NBS P   |--main.php           default layout for all views             |--column1.php &NB Sp     Use layouts for single-column pages             |--column2.php       use layouts for double-row pages         |--site/                include ' site ' controller view files     &nbs P       |--pages/            includes "static" page           &NBSP ;     |--about.php     "about" Page view             |--contact.php   &NBS P   ' Contact ' action view             |--error.php         ' ERROR ' action view (show outside Errors)             |--index.php         ' index ' action view       & nbsp &nbSp   |--login.php         ' login ' action view         |--system/      & nbsp       include system view files

Articles you may be interested in

    • PHP gets all the files in the directory and saves the results to an array of programs
    • Linux command file directory Management Cat command
    • PHP builds its own simple case of MVC framework, providing ideas for reference only
    • A simple summary of the jquery animation effect
    • Use PHP functions in Smarty Templates and how to use multiple functions for a variable in a smarty template
    • How to sort the results of database query according to the first word of Chinese characters
    • PHP Empty (delete) the file under the specified directory, do not delete the Directory folder method
    • Dedecms (Dream Weaving) website Server directory security Settings experience sharing

http://www.bkjia.com/PHPjc/979874.html www.bkjia.com true http://www.bkjia.com/PHPjc/979874.html techarticle YII Framework directory structure detailed analysis of the article described in detail the development of a project with YII directory structure and directory description, learning PHP framework Yii Friends can be collected to see. /...

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.