if (extension_loaded('mysqlnd')) // or 'mysql' or 'pdo_*'
echo 'MYSQL extension is loaded';
você também pode usar:
if (function_exists('mysql_connect'))
echo 'MYSQL functions are available';
if (extension_loaded('mysqlnd')) // or 'mysql' or 'pdo_*'
echo 'MYSQL extension is loaded';
if (function_exists('mysql_connect'))
echo 'MYSQL functions are available';