php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #40582 phpversion('extension_name') return false
Submitted: 2007-02-21 17:30 UTC Modified: 2007-02-21 17:46 UTC
From: Ox41464b at satria dot web dot id Assigned:
Status: Not a bug Package: PHP options/info functions
PHP Version: 4.4.5 OS: Irrelevant
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: Ox41464b at satria dot web dot id
New email:
PHP Version: OS:

 

 [2007-02-21 17:30 UTC] Ox41464b at satria dot web dot id
Description:
------------
phpversion didnt works like it should

Reproduce code:
---------------
<?php
print_r(get_loaded_extensions());
var_dump(phpversion('gd'));
?>

Expected result:
----------------
others... except false

Actual result:
--------------
/*
Current Result:
Array
(
    [0] => xml
    [1] => tokenizer
    [2] => standard
    [3] => sockets
    [4] => session
    [5] => posix
    [6] => overload
    [7] => mysql
    [8] => mbstring
    [9] => iconv
    [10] => gettext
    [11] => gd
    [12] => ftp
    [13] => curl
    [14] => ctype
    [15] => calendar
    [16] => bcmath
    [17] => zlib
    [18] => pcre
    [19] => openssl
    [20] => apache
    [21] => ionCube Loader
    [22] => Zend Optimizer
)
bool(false)
*/


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-02-21 17:36 UTC] tony2001@php.net
If the optional extension parameter is specified, phpversion() returns the version of that extension, 
**or FALSE if there is no version information associated** or the extension isn't enabled.
http://php.net/phpversion
 [2007-02-21 17:46 UTC] Ox41464b at satria dot web dot id
Looks like most of extensions loaded on mine is without Info
Should its reported to each extensions maintainer?

Code:
$e = get_loaded_extensions();
foreach($e as $ext_name)
{
	$v = phpversion($ext_name);
	if ($v) echo $ext_name . " version: ". $v;
	else echo $ext_name . " version: Not avaiable";
}

Result:
xml version: Not avaiable
tokenizer version: 0.1
standard version: 4.4.4
sockets version: Not avaiable
session version: Not avaiable
posix version: Not avaiable
overload version: Not avaiable
mysql version: Not avaiable
mbstring version: Not avaiable
iconv version: Not avaiable
gettext version: Not avaiable
gd version: Not avaiable
ftp version: Not avaiable
curl version: Not avaiable
ctype version: Not avaiable
calendar version: Not avaiable
bcmath version: Not avaiable
zlib version: 1.1
pcre version: Not avaiable
openssl version: Not avaiable
apache version: Not avaiable
ionCube Loader version: Not avaiable
Zend Optimizer version: Not avaiable
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 07:01:30 2024 UTC