API: Add PHP and database version to meta=siteinfo output
authorRoan Kattouw <catrope@users.mediawiki.org>
Sat, 2 May 2009 13:35:20 +0000 (13:35 +0000)
committerRoan Kattouw <catrope@users.mediawiki.org>
Sat, 2 May 2009 13:35:20 +0000 (13:35 +0000)
RELEASE-NOTES
includes/api/ApiQuerySiteinfo.php

index 06a2268..a0a7e68 100644 (file)
@@ -126,6 +126,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * (bug 18597) Internal error with empty generator= parameter
 * (bug 16422) Don't display help for format=jsonfm unless specifically requested
 * (bug 18617) Add xml:space="preserve" attribute to relevant tags in XML output
+* Added PHP and database version to meta=siteinfo output
 
 === Languages updated in 1.16 ===
 
index c4832f4..3fe9712 100644 (file)
@@ -108,6 +108,10 @@ class ApiQuerySiteinfo extends ApiQueryBase {
                $data['base'] = $mainPage->getFullUrl();
                $data['sitename'] = $GLOBALS['wgSitename'];
                $data['generator'] = "MediaWiki {$GLOBALS['wgVersion']}";
+               $data['phpversion'] = phpversion();
+               $data['phpsapi'] = php_sapi_name();
+               $data['dbclass'] = get_class($this->getDB());
+               $data['dbversion'] = $this->getDB()->getServerVersion();
 
                $svn = SpecialVersion::getSvnRevision( $GLOBALS['IP'] );
                if( $svn )