Re: Re: suggestion for pecl packages
| From: | Andrey Hristov | Date: | Mon, 27 Sep 2004 22:46:49 +0000 |
| Subject: | Re: Re: suggestion for pecl packages | ||
| References: | 1 2 3 4 5 6 7 8 | Groups: | php.pecl.dev |
| Request: | Send a blank email to pecl-dev+get-1402@lists.php.net to get a copy of this message | ||
Andrey Hristov wrote:
Sara Golemon wrote:I have copied that from pecl/smbc and in the beginning of smb.c one can see: "Smbclient 0.5 Module for PHP version 4.0". What I find as possible solution is putting $Id tag in the zend_module_entry. More or less what some extension do with the information shown from MINFO. AndreyI think that full compatibility back to 4.0.0 will be kind of impossible or? :) Many extensions has this #if ZEND_MODULE_API_NO >= 20010901 "0.1", /* Replace with version number for your extension */ #endif The ZEND_MODULE_API_NO is after the release of 4.0.0 thus not every module will give you back this info. And unfortunately in most cases devs usually don't change this version :/I'm bundling up a runkit extension as we speak, I can throw in a runkit_ext_version() function while I'm at it (which will allow access to the version ID of other extensions too). Since my goal for the extension as a whole is compatability back to 4.0.0 this should cover your need. -Sara (Who meant to have it published yesterday but it just keeps growing)As Andrey said: You can use the Reflection API to get the version numberofan extension: $ext = new ReflectionExtension("tidy'); echo $ext->getVersion();Yes I know that, it's PHP5 specific. What about PHP4 ?