#!/bin/sh -e # -*- mode: Shell-script; tab-width: 8; fill-column: 70; -*- # $Id: php.example,v 0.0.1 2005/10/28 14:10:15 legion Exp $ # # This is easy to use way to make own profile of php configuration. This way base on control(8) system. # To make new profile You must think up his name and simply add new rule to this profile. # # New rules should be added by function `php_rule'. # # php_rule <MODE> <DIRECTIVE> <VALUE> [ <INTRERNAL_VALUE> ] # <MODE> - profile name # <DIIRECTIVE> - php.ini directive # <VALUE> - value which must be specified for this profile. # # optional argument: # <INTERNAL_VALUE> - php internal representing of <VALUE>. # Example: "E_ALL & ~E_NOTICE" -> "2039" # # Also we have some predefined readonly variables: # PHP_SAPI - Service API Name (cli, cgi, mod_php ...) # PHP_VERSION - php version. # PHP_LIBDIR - php extensions location. # PHP_INI - php.ini for current PHP_SAPI . # php_on - boolean On. This variable should be uesd as <VALUE> instead Yes, On, True or 1. # php_off - boolean Off. This variable should be uesd as <VALUE> instead No, Off, False or 0. # # Example: # php_rule "crazyfrog" "safe_mode" "$php_on" # php_rule "crazyfrog" "post_max_size" "1M" # php_rule "crazyfrog" "error_reporting" "E_ALL & ~E_NOTICE" "2039" # php_rule "crazyfrog" "extension_dir" "/usr/lib/php/$PHP_VERSION/extensions/" #