Home > php教程 > PHP源码 > php获取mysql数据库版本号 mysql_get_server_info

php获取mysql数据库版本号 mysql_get_server_info

PHP中文网
Release: 2017-03-23 10:22:37
Original
2711 people have browsed it

php获取mysql数据库版本号 mysql_get_server_info

$getmysqlver=@mysql_get_server_info();
if(empty($getmysqlver))
{
$getmysqlver='5.0';
}
if($getmysqlver>='5.0')
{
$phome_db_ver='5.0';
}
elseif($getmysqlver>='4.1')
{
$phome_db_ver='4.1';
}
else
{
$phome_db_ver='4.0';
}
Copy after login

相关文章:

php获取mysql数据库中的所有表名的代码

PHP获取mysql数据库表字段的方法

PHP获取MySQL数据库里所有表的实现代码

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Articles by Author
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template