Добро пожаловать на форум PHP программистов!
За последние 24 часа нас посетил 18891 программист и 2025 роботов. Сейчас ищут 1277 программистов ...

PHP_CompatInfo::loadVersion

Вернуться к: PHP version history

PHP_CompatInfo::loadVersion

PHP_CompatInfo::loadVersion() – Load components list

Synopsis

require_once 'PHP/CompatInfo.php';

array PHP_CompatInfo::loadVersion ( string $min , string|boolean $max = false , boolean $include_const = false , boolean $groupby_vers = false )

Load components list for a PHP version or subset

Parameter

string $min

PHP minimal version

string|boolean $max

(optional) PHP maximal version

boolean $include_const

(optional) include constants list in final result

boolean $groupby_vers

(optional) give initial php version of function or constant

Return value

returns An array of php function available in version(s) given

returns A mixed array of php function + php constants available in version(s) given. Available with parameter #3 ($include_const) since API 1.6.0

Throws

throws no exceptions thrown

Since

since version 1.2.0 (2006-08-23)

Note

This function can not be called statically.

Example

What's new with PHP version 4.3.10 ?

<?php
require_once 'PHP/CompatInfo.php';

$pci = new PHP_CompatInfo();
$res $pci->loadVersion('4.3.10''4.3.10'true);
var_export($res);
?>

Result give: 0 function and 2 constants

 array (   'functions' =>   array (   ),   'constants' =>   array (     0 => 'PHP_EOL',     1 => 'UPLOAD_ERR_NO_TMP_DIR',   ), )    

What's new since PHP version 5.2.1 ?

<?php
require_once 'PHP/CompatInfo.php';

$pci = new PHP_CompatInfo();
$res $pci->loadVersion('5.2.1');
var_export($res);
?>

Result give only 4 functions (with default Extension Support List provided by version 1.9.0 of PHP_CompatInfo). Depending of your Extension Support List, this result can be different.

 array (   0 => 'php_ini_loaded_file',   1 => 'stream_is_local',   2 => 'stream_socket_shutdown',   3 => 'sys_get_temp_dir', )    



Вернуться к: PHP version history

© 2025 «PHP.RU — Сообщество PHP-Программистов»
Главная | Форум | Реклама на сайте | Контакты VIP Сувениры
Разработка компании ODware