Output buffering is not available in php 3 (bug #824956).

This commit is contained in:
Michal Čihař
2003-10-16 17:25:27 +00:00
parent d6f4f5b8d4
commit 595d59629c
2 changed files with 23 additions and 14 deletions

View File

@@ -15,6 +15,8 @@ $Source$
* libraries/common.lib.php3: Add some more fixes for wrongly typed * libraries/common.lib.php3: Add some more fixes for wrongly typed
$cfg['PmaAbsoluteUri']. $cfg['PmaAbsoluteUri'].
* Documentation: Changed my email and credits. * Documentation: Changed my email and credits.
* libraries/defines_php.lib.php3: Output buffering is not available in
php 3 (bug #824956).
2003-10-15 Marc Delisle <lem9@users.sourceforge.net> 2003-10-15 Marc Delisle <lem9@users.sourceforge.net>
* lang/russian-windows-1251: wrong charset (bug 823939) * lang/russian-windows-1251: wrong charset (bug 823939)

View File

@@ -68,6 +68,9 @@ function PMA_dl($module) {
|| (PMA_PHP_INT_VERSION < 40000 && PMA_PHP_INT_VERSION > 30009 && !@get_cfg_var('safe_mode'))) || (PMA_PHP_INT_VERSION < 40000 && PMA_PHP_INT_VERSION > 30009 && !@get_cfg_var('safe_mode')))
&& @function_exists('dl')) { && @function_exists('dl')) {
if (PMA_PHP_INT_VERSION < 40000) {
$GLOBALS['PMA_dl_allowed'] = TRUE;
} else {
ob_start(); ob_start();
phpinfo(INFO_GENERAL); /* Only general info */ phpinfo(INFO_GENERAL); /* Only general info */
$a = strip_tags(ob_get_contents()); $a = strip_tags(ob_get_contents());
@@ -82,6 +85,7 @@ function PMA_dl($module) {
} else { } else {
$GLOBALS['PMA_dl_allowed'] = TRUE; $GLOBALS['PMA_dl_allowed'] = TRUE;
} }
}
} else { } else {
$GLOBALS['PMA_dl_allowed'] = FALSE; $GLOBALS['PMA_dl_allowed'] = FALSE;
} }
@@ -119,7 +123,7 @@ if (!defined('PMA_IS_GD2')) {
} else { } else {
define('PMA_IS_GD2', 0); define('PMA_IS_GD2', 0);
} }
} else { } elseif (PMA_PHP_INT_VERSION >= 40000) {
/* We must do hard way... */ /* We must do hard way... */
ob_start(); ob_start();
phpinfo(INFO_MODULES); /* Only modules */ phpinfo(INFO_MODULES); /* Only modules */
@@ -135,6 +139,9 @@ if (!defined('PMA_IS_GD2')) {
} else { } else {
define('PMA_IS_GD2', 0); define('PMA_IS_GD2', 0);
} }
} else {
// This is PHP 3 version, it probably doesn't have GD2
define('PMA_IS_GD2', 0);
} }
} }
} }