Zend Framework Tutorial configuration file Application.ini parsing, php.inizend configuration
This article analyzes the Zend Framework configuration file Application.ini usage. Share to everyone for your reference, as follows:
The most convenient and commonly used configuration method is to use the configuration file. The specific setting options for the configuration file are as follows:
PHP.ini the relevant configuration options, in the following format:
Phpsettings. Configuration options, such as
phpsettings.display_startup_errors = 1phpsettings.display_errors = 1
Includepath Related Configurations
Includepaths.library = Application_path "/.. /library "includepaths.zend = Application_path"/... /.. /library "
The location of the boot class
Bootstrap.path = Application_path "/bootstrap.php"
Boot class name
Bootstrap.class = "Bootstrap"
Default namespace
Appnamespace = "Application"
Custom namespaces
Whether to show exceptions
Configuration of resources
If your app uses a modular approach
Custom Layout plug-ins
Resources.frontController.plugins.layout = Abc_controller_plugin_layout
File directory for layout
Resources.layout.layoutPath = Application_path "/layouts/scripts"
The default Laytou
Resources.layout.layout = Default
Customizing the helper Path
Copy the Code code as follows: Resources.view.helperPath.App_View_Helper = Application_path "/modules/default/views/helpers"
Set Sessiong
Session.lifetime = 3600
Set the time
Datetime.timezone = "Asia/shanghai" datetime.format.date = "m-d-y" datetime.format.datetime = "M-d-y h:i:s"
Configuration of the database
Db.adapter = "Pdo_mysql" Db.prefix = "pre_" db.host = "localhost" db.port = "3306" db.dbname = "db" db.username = "root" db.pass Word = "" Db.charset = "UTF8"
Configuration of the Log
Log.adapter = pdo_mysqllog.params.host = Localhostlog.params.port = 3306log.params.username = Rootlog.params.password = Log.params.dbname = Testlog.params.charset = utf8log.params.profiler.enabled = Truelog.params.profiler.class = Zend_db_profiler_firebug
More interested in Zend related content readers can view the topic: "Zend framework of the introductory tutorial", "PHP Excellent Development Framework Summary", "Yii framework Introduction and common skills Summary", "thinkphp Introductory Tutorial", "PHP object-oriented Programming introduction tutorial "," Introduction to Php+mysql Database Operation "and" PHP common database Operation Skills Summary "
I hope this article is helpful to you in PHP programming.
Articles you may be interested in:
- Zend Framework Tutorial Loader and Pluginloader usage
- Zend Framework Tutorial Autoloading Usage
- Examples of resource autoloading usages of the Zend framework tutorial
- Controller usage Analysis of MVC Framework for Zend Framework Tutorial
- Zend Framework Tutorial's routing function zend_controller_router detailed
- Zend Framework Tutorial Zend_controller_plugin plugin Usage
- Package Zend_controller_response Example of response object for Zend Framework tutorial
- Package Zend_controller_request example of request object for Zend Framework tutorial
- Zend Framework Tutorial Action base class Zend_controller_action detailed
- Zend Framework Tutorial Distributor Zend_controller_dispatcher Usage
- Zend Framework Tutorial Front Controller Zend_controller_front Usage
- Zend Framework Tutorial application and bootstrap usage
http://www.bkjia.com/PHPjc/1108611.html www.bkjia.com true http://www.bkjia.com/PHPjc/1108611.html techarticle Zend Framework Tutorial configuration file Application.ini Parsing, php.inizend configuration This article analyzes the Zend framework configuration file Application.ini usage. Share to everyone for your reference, specific as ...