= 40000 && !@ini_get('safe_mode') && @ini_get('enable_dl')) || (PMA_PHP_INT_VERSION < 40000 && PMA_PHP_INT_VERSION > 30009 && !@get_cfg_var('safe_mode'))) && @function_exists('dl')) { ob_start(); phpinfo(INFO_GENERAL); /* Only general info */ $a = strip_tags(ob_get_contents()); ob_end_clean(); /* Get GD version string from phpinfo output */ if (ereg('Thread Safety[[:space:]]*enabled', $a)) { if (ereg('Server API[[:space:]]*\(CGI\|CLI\)', $a)) { $GLOBALS['PMA_dl_allowed'] = TRUE; } else { $GLOBALS['PMA_dl_allowed'] = FALSE; } } else { $GLOBALS['PMA_dl_allowed'] = TRUE; } } else { $GLOBALS['PMA_dl_allowed'] = FALSE; } } if (PMA_IS_WINDOWS) { $suffix = '.dll'; } else { $suffix = '.so'; } if ($GLOBALS['PMA_dl_allowed']) { return @dl($module . $suffix); } else { return FALSE; } } // Whether GD2 is present if (!defined('PMA_IS_GD2')) { if ($cfg['GD2Available'] == 'yes') { define('PMA_IS_GD2', 1); } elseif ($cfg['GD2Available'] == 'no') { define('PMA_IS_GD2', 0); } else { if (!@extension_loaded('gd')) { PMA_dl('gd'); } if (!@function_exists('imagecreatetruecolor')) { define('PMA_IS_GD2', 0); } else { if (@function_exists('gd_info')) { $gd_nfo = gd_info(); if (strstr($gd_nfo["GD Version"], '2.')) { define('PMA_IS_GD2', 1); } else { define('PMA_IS_GD2', 0); } } else { /* We must do hard way... */ ob_start(); phpinfo(INFO_MODULES); /* Only modules */ $a = strip_tags(ob_get_contents()); ob_end_clean(); /* Get GD version string from phpinfo output */ if (ereg('GD Version[[:space:]]*\(.*\)', $a, $v)) { if (strstr($v, '2.')) { define('PMA_IS_GD2', 1); } else { define('PMA_IS_GD2', 0); } } else { define('PMA_IS_GD2', 0); } } } } } // $__PMA_DEFINES_PHP_LIB__ ?>