enable more features when relation is broken

This commit is contained in:
Marc Delisle
2003-06-12 14:50:05 +00:00
parent 89bf261bdf
commit a32ffd69c3
2 changed files with 33 additions and 29 deletions

View File

@@ -5,6 +5,10 @@ phpMyAdmin - Changelog
$Id$
$Source$
2003-06-12 Marc Delisle <lem9@users.sourceforge.net>
* libraries/relation.lib.php3: bug 751787: should not disable all
the features, when the relation feature is broken
2003-06-11 Marc Delisle <lem9@users.sourceforge.net>
* libraries/auth/cookie.auth.lib.php3: undefined scheme
* main.php3: undefined scheme

View File

@@ -137,41 +137,41 @@ if (!defined('PMA_RELATION_LIB_INCLUDED')){
if (isset($cfgRelation['relation'])) {
$cfgRelation['relwork'] = TRUE;
if (isset($cfgRelation['table_info'])) {
$cfgRelation['displaywork'] = TRUE;
$cfgRelation['displaywork'] = TRUE;
}
if (isset($cfgRelation['table_coords']) && isset($cfgRelation['pdf_pages'])) {
$cfgRelation['pdfwork'] = TRUE;
}
if (isset($cfgRelation['column_info'])) {
$cfgRelation['commwork'] = TRUE;
if ($cfg['Server']['verbose_check']) {
$mime_query = 'SHOW FIELDS FROM ' . PMA_backquote($cfgRelation['db']) . '.' . PMA_backquote($cfgRelation['column_info']);
$mime_rs = PMA_query_as_cu($mime_query, FALSE);
}
if (isset($cfgRelation['table_coords']) && isset($cfgRelation['pdf_pages'])) {
$cfgRelation['pdfwork'] = TRUE;
}
if (isset($cfgRelation['column_info'])) {
$cfgRelation['commwork'] = TRUE;
if ($cfg['Server']['verbose_check']) {
$mime_query = 'SHOW FIELDS FROM ' . PMA_backquote($cfgRelation['db']) . '.' . PMA_backquote($cfgRelation['column_info']);
$mime_rs = PMA_query_as_cu($mime_query, FALSE);
$mime_field_mimetype = FALSE;
$mime_field_transformation = FALSE;
$mime_field_transformation_options = FALSE;
while ($curr_mime_field = @PMA_mysql_fetch_array($mime_rs)) {
if ($curr_mime_field[0] == 'mimetype') {
$mime_field_mimetype = TRUE;
} else if ($curr_mime_field[0] == 'transformation') {
$mime_field_transformation = TRUE;
} else if ($curr_mime_field[0] == 'transformation_options') {
$mime_field_transformation_options = TRUE;
}
$mime_field_mimetype = FALSE;
$mime_field_transformation = FALSE;
$mime_field_transformation_options = FALSE;
while ($curr_mime_field = @PMA_mysql_fetch_array($mime_rs)) {
if ($curr_mime_field[0] == 'mimetype') {
$mime_field_mimetype = TRUE;
} else if ($curr_mime_field[0] == 'transformation') {
$mime_field_transformation = TRUE;
} else if ($curr_mime_field[0] == 'transformation_options') {
$mime_field_transformation_options = TRUE;
}
if ($mime_field_mimetype == TRUE
&& $mime_field_transformation == TRUE
&& $mime_field_transformation_options == TRUE) {
$cfgRelation['mimework'] = TRUE;
}
} else {
}
if ($mime_field_mimetype == TRUE
&& $mime_field_transformation == TRUE
&& $mime_field_transformation_options == TRUE) {
$cfgRelation['mimework'] = TRUE;
}
} else {
$cfgRelation['mimework'] = TRUE;
}
} // end if
}
if (isset($cfgRelation['history'])) {
$cfgRelation['historywork'] = TRUE;