INI Settings

int zend_alter_ini_entry(char *name, uint name_length,
 char *value, uint value_length,
 int modify_type, int stage);
int zend_restore_ini_entry(char *name, uint name_length, int stage);

Changes or restores an INI setting.

Argument

Purpose

name

NULL-terminated name of INI entry being modified.

name_length

Length of name including the trailing NULL byte.

value

New value as a text string, regardless of what the ultimate storage type is. NULL-terminated as always.

value_length

Length of value excluding the trailing NULL byte.

modify_type

Calling scope's declared access level; must contain the same level as the option being modified but can include other levels as well: PHP_INI_SYSTEM, PHP_INI_PERDIR, PHP_INI_USER.

stage

Current execution stage of the Zend Engine. One of: PHP_INI_STAGE_STARTUP, PHP_INI_STAGE_ACTIVATE, PHP_INI_STAGE_RUNTIME, PHP_INI_STAGE_DEACTIVATE, PHP_INI_STAGE_SHUTDOWN.

long zend_ini_long(char *name, uint name_length, int orig);
double zend_ini_double(char *name, uint name_length, int orig);
char *zend_ini_string(char *name, uint name_length, int orig);

Fetches and converts an INI value. These API functions also come wrapped in macros such as INI_STR() or INI_ORIG_LONG(); refer to Chapter 13, "INI Settings," for more information.

Argument

Purpose

name

NULL-terminated name of INI option to look up.

length

Length of name including trailing NULL byte.

orig

When set to zero, the current INI settingwhich might have been overriddenwill be returned. Otherwise, the original, unmodified setting will be returned.



The PHP Life Cycle

Variables from the Inside Out

Memory Management

Setting Up a Build Environment

Your First Extension

Returning Values

Accepting Parameters

Working with Arrays and HashTables

The Resource Data Type

PHP4 Objects

PHP5 Objects

Startup, Shutdown, and a Few Points in Between

INI Settings

Accessing Streams

Implementing Streams

Diverting the Stream

Configuration and Linking

Extension Generators

Setting Up a Host Environment

Advanced Embedding

Appendix A. A Zend API Reference

Appendix B. PHPAPI

Appendix C. Extending and Embedding Cookbook

Appendix D. Additional Resources



Extending and Embedding PHP
Extending and Embedding PHP
ISBN: 067232704X
EAN: 2147483647
Year: 2007
Pages: 175
Authors: Sara Golemon

Similar book on Amazon

Flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net