From 01f16dc6e5ff7b8f751b31c6146759f5bfa791a8 Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Fri, 23 Mar 2007 16:52:32 +0000 Subject: [PATCH] patch #1681620 [interface] support reordering of ['ColumnTypes'] --- ChangeLog | 2 ++ libraries/database_interface.lib.php | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 743019e2e..4684dad2b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -61,6 +61,8 @@ $HeadURL: https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/trunk/phpMyA - bug #1674972 [export] no export with %afm% - bug #1667887 HTML maxlength - bug #1679055 #1050 - Table '' already exists +- patch #1681620 [interface] support reordering of $cfg['ColumnTypes'], + thanks to Leonard den Ottolander 2.10.0.3 (not released yet) ===================== diff --git a/libraries/database_interface.lib.php b/libraries/database_interface.lib.php index 25a41c41d..4b9046f78 100644 --- a/libraries/database_interface.lib.php +++ b/libraries/database_interface.lib.php @@ -868,11 +868,12 @@ function PMA_DBI_postConnect($link, $is_controluser = false) } // Add some field types to the list, this needs to be done once per session! - if ($GLOBALS['cfg']['ColumnTypes'][count($GLOBALS['cfg']['ColumnTypes']) - 1] != 'VARBINARY') { + if (!in_array('BINARY', $GLOBALS['cfg']['ColumnTypes'])) { $GLOBALS['cfg']['ColumnTypes'][] = 'BINARY'; + } + if (!in_array('VARBINARY', $GLOBALS['cfg']['ColumnTypes'])) { $GLOBALS['cfg']['ColumnTypes'][] = 'VARBINARY'; } - } else { require_once('./libraries/charset_conversion.lib.php'); }