Display the drop-down list
docs/function-configuration.txt rendered in HTML with pbx_text_to_html
Function configuration

Note that this document is a rough draft and incomplete.

the $constant_prefix property

- this property specifies the prefix of constants to filter from get_defined_constants(), see synopsis::get_arg_constant_name_prefix()
- the list of constants id used to display the arg helper, see input::display_arg_helper()
- format: public $constant_prefix = [<arg_name> => <constant_prefix>, ... ];
- eg public $constant_prefix = ['calendar' => 'CAL'];

the $synopsis property

- this property has a copy of the synopsis extracted from the function manual page
- the synopsis is used to extract arg names, arg types etc.
- eg public $synopsis = 'number abs ( mixed $number )';
- the synopsis is occasionally altered for parsing purposes
  eg public $synopsis_fixed = 'array array_merge_recursive ( array $array1 , array $array2 [, array $... ] )';

other properties

public $commented_options = ['zenith' => [ [90, '     horizon'], ...]]
public $commented_options_getter = ['country' => 'pbx_get_two_letter_country_codes'];
public $constant_prefix = ['calendar' => 'CAL']; or ['fetch_style' => 'PDO::FETCH']; or ['value' => 'PDO::'];
public $constant_as_string = ['name' => true];
public $hash_result = true; or 'pcre', ['pcre', ...] or '~^(pcre|...)~'
public $helper_callbacks = ['index_in_example' => 2, 'function_name_pattern' => '~(cmp$)~'];
public $input_args = ['__array1', '__array2', '__array3'];
public $manual_function_name = "Locale::composeLocale";
public $method_to_exec = 'getBrowser'; or false
public $multi_select = ['fl' => true];
public $no_input_args = 'use_include_path';
public $no_object_name = true;
public $options_getter = ['encoding' => 'mb_list_encodings'];
public $options_list = ['mode' => ['a', 'a+', 'c', 'c+', 'r', 'r+', 'w', 'w+', 'x', 'x+']];
  see also public function _get_options_list();
public $options_range = ['mode' => [0, 4]];
public $output_buffer = true;
public $see_also = ['call_user_funct'];
  see also filter_callback()
public $synopsis_fixed
public $synopsis_to_exec
public $test_not_to_run = true; or [1, 2];
public $test_not_validated = true; or [1, 3, 4, 6];

Example values

- scalars and arrays are allowed, eg 123 , 'abc' , "def\nghi" , [123, 'a' => ['xyz']]
- expressions and operators are not allowed, excepted for constants

- escaped characters in a string enclosed in double quotes are interpreted, eg "abc\ndef", see parser::parse_string()
- variables within a string are not allowed

- a variable must be enclosed with single quotes, eg '$var'
- a constant must be enclosed with quotes, eg 'E_ERROR', it will converted to its value automatically
- a list of constants must be enclosed with quotes and separated with "|", eg 'ENT_QUOTES | ENT_IGNORE'
- false, true, null must not be enclosed with quotes, otherwise there are considered as string

- use _NO_CHANGE_ to display the string as it is, for example to force invalid input, eg '_NO_CHANGE_123"456'
- use _DOUBLE_QUOTES_ to force the string to be enclosed with double quotes, eg '_DOUBLE_QUOTES_\n_DOUBLE_QUOTES_'
- use _SINGLE_QUOTE_ to force the string to be enclosed with single quotes, eg '_SINGLE_QUOTE_/\d/_SINGLE_QUOTE_'
- use _NO_QUOTE_ to force the string not to be enclosed with quotes, eg '_NO_QUOTE_0x30'
- a regex pattern should ideally be enclosed between single quotes, eg '_SINGLE_QUOTE_/(<([\w]+)[^>]*>)(.*?)(<\/\2>)/_SINGLE_QUOTE_'
- a regex pattern entered between double quotes may produce unexpected behavior for parsing reasons, see parser::parse_string()

Source code


Doc block

 * Changes to this class may affect other classes.

PHP by Example
Copyright 2015 Michel Corne 
License   http://www.opensource.org/licenses/gpl-3.0.html GNU GPL v3