From 617545f8f27c373c83b4438cdcce5267e5de0fd3 Mon Sep 17 00:00:00 2001 From: "Alexander M. Turek" Date: Sat, 28 Sep 2002 15:48:16 +0000 Subject: [PATCH] IIS 6.0 compatibility --- ChangeLog | 11 ++++++++--- libraries/common.lib.php3 | 2 +- libraries/config_import.lib.php3 | 3 +++ 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index bda29db2e..7f05db8bb 100755 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,11 @@ phpMyAdmin - Changelog $Id$ $Source$ +2002-09-28 Alexander M. Turek + * libraries/common.lib.php3: $cfg['PmaAbsoluteURI'] detection did not work + properly on IIS 6.0. + * libraries/config_import.lib.php3: Fixed an inconsitence. + 2002-09-27 Loïc Chapeaux * db_details_qbe.php3: PHP3 fixes & coding standards. * db_details_importdocsql.php3: optimization, xhtml fixes & coding @@ -29,7 +34,7 @@ $Source$ 2002-09-24 Michal Cihar * lang/czech-*.inc.php3: update - + 2002-09-23 Marc Delisle * lang/japanese: update, thanks to Yukihiro Kawada * lang/italian: update, thanks to Pietro Danesi @@ -44,11 +49,11 @@ $Source$ 2002-09-23 Michal Cihar * libraries/sqlparser.lib.php3: fix for #613102 (ALTER TABLE:missing spacebar) - + 2002-09-22 Loïc Chapeaux * tbl_relation.php3: fix fox #611519 (slash in comment) * libraries/sqlparser.lib.php3: coding standards - + 2002-09-21 Alexander M. Turek * lang/german-*.inc.php3: Updates. * libraries/common.lib.php3, libraries/config_import.lib.php3: Backwards diff --git a/libraries/common.lib.php3 b/libraries/common.lib.php3 index 1f1c69c82..a3042a48c 100644 --- a/libraries/common.lib.php3 +++ b/libraries/common.lib.php3 @@ -467,7 +467,7 @@ h1 {font-family: sans-serif; font-size: large; font-weight: bold} // page. if (empty($cfg['PmaAbsoluteUri'])) { $port_in_HTTP_HOST = (strpos($HTTP_SERVER_VARS['HTTP_HOST'], ':') > 0); - $cfg['PmaAbsoluteUri'] = (!empty($HTTP_SERVER_VARS['HTTPS']) ? 'https' : 'http') . '://' + $cfg['PmaAbsoluteUri'] = ((!empty($HTTP_SERVER_VARS['HTTPS']) && strtolower($HTTP_SERVER_VARS['HTTPS']) != 'off') ? 'https' : 'http') . '://' . $HTTP_SERVER_VARS['HTTP_HOST'] . ((!empty($HTTP_SERVER_VARS['SERVER_PORT']) && !$port_in_HTTP_HOST) ? ':' . $HTTP_SERVER_VARS['SERVER_PORT'] : '') . substr($PHP_SELF, 0, strrpos($PHP_SELF, '/') + 1); diff --git a/libraries/config_import.lib.php3 b/libraries/config_import.lib.php3 index 87408a5ee..c93c95c21 100644 --- a/libraries/config_import.lib.php3 +++ b/libraries/config_import.lib.php3 @@ -30,6 +30,9 @@ if (!defined('PMA_CONFIG_IMPORT_LIB_INCLUDED')){ if (isset($cfg['Servers'])) { for ($i=1; (!empty($cfg['Servers'][$i]['host']) || (isset($cfg['Servers'][$i]['connect_type']) && $cfg['Servers'][$i]['connect_type'] == 'socket')); $i++) { + if (!isset($cfg['Servers'][$i]['host'])) { + $cfg['Servers'][$i]['host'] = ''; + } if (!isset($cfg['Servers'][$i]['port'])) { $cfg['Servers'][$i]['port'] = ''; }