Home php教程 PHP开发 Zend Framework tutorial configuration file application.ini analysis

Zend Framework tutorial configuration file application.ini analysis

Dec 27, 2016 pm 02:41 PM

This article analyzes the usage of Zend Framework configuration file application.ini. Share it with everyone for your reference, the details are as follows:

The most convenient and commonly used configuration method is to use the configuration file. The specific related setting options of the configuration file are as follows:

The related configuration options of php.ini, the specific format is as follows:

phpSettings. Configuration options, such as

phpSettings.display_startup_errors = 1
phpSettings.display_errors = 1
Copy after login

includePath related configuration

includePaths.library = APPLICATION_PATH "/../library"
includePaths.zend = APPLICATION_PATH "/../../Library"
Copy after login

The location of the boot class

bootstrap.path = APPLICATION_PATH "/Bootstrap.php"
Copy after login

Boot class name

bootstrap.class = "Bootstrap"
Copy after login

Default namespace

appnamespace = "Application"
Copy after login

Since Define the namespace

autoloadernamespaces.app = "App_"
Copy after login

Whether to display exception

resources.frontController.params.displayExceptions
Copy after login

Configuration of resources

If the application uses a modular approach

resources.frontController.moduleDirectory = APPLICATION_PATH "/modules"
resources.modules[] =
Copy after login

Custom layout plug-in

resources.frontController.plugins.layout = Abc_Controller_Plugin_Layout
Copy after login

layout file directory

resources.layout.layoutPath = APPLICATION_PATH "/layouts/scripts"
Copy after login

Default laytou

resources.layout.layout = default
Copy after login

Customized helper path

resources.view.helperPath.App_View_Helper = APPLICATION_PATH "/modules/default/views/helpers"
Copy after login

Set sessiong

session.lifetime = 3600
Copy after login

Set time

datetime.timezone = "Asia/Shanghai"
datetime.format.date = "m-d-Y"
datetime.format.datetime = "m-d-Y H:i:s"
Copy after login

Database Configuration

db.adapter = "pdo_mysql"
db.prefix = "pre_"
db.host = "localhost"
db.port = "3306"
db.dbname = "db"
db.username = "root"
db.password = ""
db.charset = "utf8"
Copy after login

Log configuration

log.adapter          = pdo_mysql
log.params.host        = localhost
log.params.port        = 3306
log.params.username      = root
log.params.password      =
log.params.dbname       = test
log.params.charset       = utf8
log.params.profiler.enabled  = true
log.params.profiler.class   = Zend_Db_Profiler_Firebug
Copy after login

I hope this article will be helpful to everyone PHP Programming helps.

For more Zend Framework tutorial configuration file application.ini analysis related articles, please pay attention to the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)