bug #1352479, message if no session support

This commit is contained in:
Marc Delisle
2005-11-10 20:02:48 +00:00
parent 24dac8b4e2
commit 001062a994
3 changed files with 26 additions and 1 deletions

View File

@@ -5,6 +5,10 @@ phpMyAdmin - Changelog
$Id$
$Source$
2005-11-10 Marc Delisle <lem9@users.sourceforge.net>
* libraries/session.inc.php, Documentation.html: bug #1352479, warn
if PHP does not support session
2005-11-10 Michal Čihař <michal@cihar.com>
* scripts/create-release.sh: = is correct for comparsion in shell.

View File

@@ -66,7 +66,7 @@
<li>
<b>PHP</b>
<ul>
<li>You need PHP 4.1.0 or newer (<a href="#faq1_31">*</a>)</li>
<li>You need PHP 4.1.0 or newer, with <tt>session</tt> support (<a href="#faq1_31">*</a>)</li>
<li>If you want to display inline thumbnails of JPEGs with the
original aspect ratio, you also need GD2 support in PHP</li>
<li>Starting with phpMyAdmin 2.6.1, MIME-based transformations

View File

@@ -14,6 +14,27 @@
* @uses PHP_VERSION
*/
// verify if PHP supports session, die if it does not
if (!@function_exists('session_name')) {
$cfg = array('DefaultLang' => 'en-iso-8859-1',
'AllowAnywhereRecoding' => FALSE);
// Loads the language file
require_once('./libraries/select_lang.lib.php');
// Displays the error message
// (do not use &amp; for parameters sent by header)
header( 'Location: error.php'
. '?lang=' . urlencode( $available_languages[$lang][2] )
. '&char=' . urlencode( $charset )
. '&dir=' . urlencode( $text_dir )
. '&type=' . urlencode( $strError )
. '&error=' . urlencode(
sprintf($strCantLoad, 'session'))
);
exit();
}
// disable starting of sessions before all settings are done
ini_set( 'session.auto_start', false );