This commit is contained in:
Marc Delisle
2002-04-24 20:38:38 +00:00
parent 8f4c068509
commit c2110be0af
3 changed files with 22 additions and 22 deletions

View File

@@ -143,12 +143,12 @@ if (isset($primary_key)) {
echo "\n"; echo "\n";
?> ?>
<table border="<?php echo $cfgBorder; ?>"> <table border="<?php echo $cfg['Border']; ?>">
<tr> <tr>
<th><?php echo $strField; ?></th> <th><?php echo $strField; ?></th>
<th><?php echo $strType; ?></th> <th><?php echo $strType; ?></th>
<?php <?php
if ($cfgShowFunctionFields) { if ($cfg['ShowFunctionFields']) {
echo ' <th>' . $strFunction . '</th>' . "\n"; echo ' <th>' . $strFunction . '</th>' . "\n";
} }
?> ?>
@@ -172,7 +172,7 @@ for ($i = 0; $i < $fields_cnt; $i++) {
: @mysql_field_len($result, $i); : @mysql_field_len($result, $i);
$first_timestamp = 0; $first_timestamp = 0;
$bgcolor = ($i % 2) ? $cfgBgcolorOne : $cfgBgcolorTwo; $bgcolor = ($i % 2) ? $cfg['BgcolorOne'] : $cfg['BgcolorTwo'];
?> ?>
<tr> <tr>
<td align="center" bgcolor="<?php echo $bgcolor; ?>"><?php echo htmlspecialchars($field); ?></td> <td align="center" bgcolor="<?php echo $bgcolor; ?>"><?php echo htmlspecialchars($field); ?></td>
@@ -252,9 +252,9 @@ for ($i = 0; $i < $fields_cnt; $i++) {
// Note: from the MySQL manual: "BINARY doesn't affect how the column is // Note: from the MySQL manual: "BINARY doesn't affect how the column is
// stored or retrieved" so it does not mean that the contents is // stored or retrieved" so it does not mean that the contents is
// binary // binary
if ($cfgShowFunctionFields) { if ($cfg['ShowFunctionFields']) {
if (($cfgProtectBinary && $is_blob) if (($cfg['ProtectBinary'] && $is_blob)
|| ($cfgProtectBinary == 'all' && $is_binary)) { || ($cfg['ProtectBinary'] == 'all' && $is_binary)) {
echo ' <td align="center" bgcolor="'. $bgcolor . '">' . $strBinary . '</td>' . "\n"; echo ' <td align="center" bgcolor="'. $bgcolor . '">' . $strBinary . '</td>' . "\n";
} else if (strstr($row_table_def['True_Type'], 'enum') || strstr($row_table_def['True_Type'], 'set')) { } else if (strstr($row_table_def['True_Type'], 'enum') || strstr($row_table_def['True_Type'], 'set')) {
echo ' <td align="center" bgcolor="'. $bgcolor . '">--</td>' . "\n"; echo ' <td align="center" bgcolor="'. $bgcolor . '">--</td>' . "\n";
@@ -266,14 +266,14 @@ for ($i = 0; $i < $fields_cnt; $i++) {
<?php <?php
echo "\n"; echo "\n";
$selected = ''; $selected = '';
for ($j = 0; $j < count($cfgFunctions); $j++) { for ($j = 0; $j < count($cfg['Functions']); $j++) {
// for default function = NOW() on first timestamp field // for default function = NOW() on first timestamp field
// -- swix/18jul01 // -- swix/18jul01
$selected = ($first_timestamp && $cfgFunctions[$j] == 'NOW') $selected = ($first_timestamp && $cfg['Functions'][$j] == 'NOW')
? ' selected="selected"' ? ' selected="selected"'
: ''; : '';
echo ' '; echo ' ';
echo '<option' . $selected . '>' . $cfgFunctions[$j] . '</option>' . "\n"; echo '<option' . $selected . '>' . $cfg['Functions'][$j] . '</option>' . "\n";
} // end for } // end for
unset($selected); unset($selected);
?> ?>
@@ -281,13 +281,13 @@ for ($i = 0; $i < $fields_cnt; $i++) {
</td> </td>
<?php <?php
} }
} // end if ($cfgShowFunctionFields) } // end if ($cfg['ShowFunctionFields'])
echo "\n"; echo "\n";
// The null column // The null column
// --------------- // ---------------
echo ' <td bgcolor="' . $bgcolor . '">' . "\n"; echo ' <td bgcolor="' . $bgcolor . '">' . "\n";
if (!(($cfgProtectBinary && $is_blob) || ($cfgProtectBinary == 'all' && $is_binary)) if (!(($cfg['ProtectBinary'] && $is_blob) || ($cfg['ProtectBinary'] == 'all' && $is_binary))
&& $row_table_def['Null'] == 'YES') { && $row_table_def['Null'] == 'YES') {
echo ' <input type="checkbox" tabindex=' . ($i+3*$fields_cnt) . '"' echo ' <input type="checkbox" tabindex=' . ($i+3*$fields_cnt) . '"'
. ' name="fields_null[' . urlencode($field) . ']"'; . ' name="fields_null[' . urlencode($field) . ']"';
@@ -319,7 +319,7 @@ for ($i = 0; $i < $fields_cnt; $i++) {
?> ?>
<td bgcolor="<?php echo $bgcolor; ?>"> <td bgcolor="<?php echo $bgcolor; ?>">
<?php echo $backup_field . "\n"; ?> <?php echo $backup_field . "\n"; ?>
<textarea name="fields[<?php echo urlencode($field); ?>]" rows="<?php echo $cfgTextareaRows; ?>" cols="<?php echo $cfgTextareaCols; ?>" wrap="virtual" <?php echo $chg_evt_handler; ?>="return unNullify('<?php echo urlencode($field); ?>')" tabindex="<?php echo $i; ?>"><?php echo $special_chars; ?></textarea> <textarea name="fields[<?php echo urlencode($field); ?>]" rows="<?php echo $cfg['TextareaRows']; ?>" cols="<?php echo $cfg['TextareaCols']; ?>" wrap="virtual" <?php echo $chg_evt_handler; ?>="return unNullify('<?php echo urlencode($field); ?>')" tabindex="<?php echo $i; ?>"><?php echo $special_chars; ?></textarea>
</td> </td>
<?php <?php
echo "\n"; echo "\n";
@@ -426,8 +426,8 @@ for ($i = 0; $i < $fields_cnt; $i++) {
// Change by Bernard M. Piller <bernard@bmpsystems.com> // Change by Bernard M. Piller <bernard@bmpsystems.com>
// We don't want binary data destroyed // We don't want binary data destroyed
else if ($is_binary || $is_blob) { else if ($is_binary || $is_blob) {
if (($cfgProtectBinary && $is_blob) if (($cfg['ProtectBinary'] && $is_blob)
|| ($cfgProtectBinary == 'all' && $is_binary)) { || ($cfg['ProtectBinary'] == 'all' && $is_binary)) {
echo "\n"; echo "\n";
?> ?>
<td align="center" bgcolor="<?php echo $bgcolor; ?>"> <td align="center" bgcolor="<?php echo $bgcolor; ?>">
@@ -439,7 +439,7 @@ for ($i = 0; $i < $fields_cnt; $i++) {
?> ?>
<td bgcolor="<?php echo $bgcolor; ?>"> <td bgcolor="<?php echo $bgcolor; ?>">
<?php echo $backup_field . "\n"; ?> <?php echo $backup_field . "\n"; ?>
<textarea name="fields[<?php echo urlencode($field); ?>]" rows="<?php echo $cfgTextareaRows; ?>" cols="<?php echo $cfgTextareaCols; ?>" wrap="virtual" <?php echo $chg_evt_handler; ?>="return unNullify('<?php echo urlencode($field); ?>')" tabindex="<?php echo $i+1; ?>" ><?php echo $special_chars; ?></textarea> <textarea name="fields[<?php echo urlencode($field); ?>]" rows="<?php echo $cfg['TextareaRows']; ?>" cols="<?php echo $cfg['TextareaCols']; ?>" wrap="virtual" <?php echo $chg_evt_handler; ?>="return unNullify('<?php echo urlencode($field); ?>')" tabindex="<?php echo $i+1; ?>" ><?php echo $special_chars; ?></textarea>
</td> </td>
<?php <?php
} else { } else {

View File

@@ -97,7 +97,7 @@ $err_url = 'tbl_properties.php3'
/** /**
* Increase time limit for script execution and initializes some variables * Increase time limit for script execution and initializes some variables
*/ */
@set_time_limit($cfgExecTimeLimit); @set_time_limit($cfg['ExecTimeLimit']);
$dump_buffer = ''; $dump_buffer = '';
// Defines the default <CR><LF> format // Defines the default <CR><LF> format
$crlf = PMA_whichCrlf(); $crlf = PMA_whichCrlf();

View File

@@ -34,7 +34,7 @@ if (!defined('PMA_IDX_INCLUDED')) {
$is_db = @mysql_select_db($db); $is_db = @mysql_select_db($db);
} }
if (empty($db) || !$is_db) { if (empty($db) || !$is_db) {
header('Location: ' . $cfgPmaAbsoluteUri . 'main.php3?lang=' . $lang . '&server=' . $server . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1'); header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?lang=' . $lang . '&server=' . $server . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
exit(); exit();
} }
// Not a valid table name -> back to the db_details.php3 // Not a valid table name -> back to the db_details.php3
@@ -42,7 +42,7 @@ if (!defined('PMA_IDX_INCLUDED')) {
$is_table = @mysql_query("SHOW TABLES LIKE '" . PMA_sqlAddslashes($table, TRUE) . '\''); $is_table = @mysql_query("SHOW TABLES LIKE '" . PMA_sqlAddslashes($table, TRUE) . '\'');
} }
if (empty($table) || !@mysql_numrows($is_table)) { if (empty($table) || !@mysql_numrows($is_table)) {
header('Location: ' . $cfgPmaAbsoluteUri . 'db_details.php3?lang=' . $lang . '&server=' . $server . '&db=' . urlencode($db) . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1'); header('Location: ' . $cfg['PmaAbsoluteUri'] . 'db_details.php3?lang=' . $lang . '&server=' . $server . '&db=' . urlencode($db) . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
exit(); exit();
} else if (isset($is_table)) { } else if (isset($is_table)) {
mysql_free_result($is_table); mysql_free_result($is_table);
@@ -340,7 +340,7 @@ else if (!defined('PMA_IDX_INCLUDED')
</tr> </tr>
</table><br /> </table><br />
<table border="<?php echo $cfgBorder; ?>" cellpadding="5"> <table border="<?php echo $cfg['Border']; ?>" cellpadding="5">
<tr> <tr>
<th><?php echo $strField; ?></th> <th><?php echo $strField; ?></th>
<th><?php echo $strSize; ?></th> <th><?php echo $strSize; ?></th>
@@ -354,7 +354,7 @@ else if (!defined('PMA_IDX_INCLUDED')
} else { } else {
$sub_part = ''; $sub_part = '';
} }
$bgcolor = (($row_no % 2) ? $cfgBgcolorOne : $cfgBgcolorTwo); $bgcolor = (($row_no % 2) ? $cfg['BgcolorOne'] : $cfg['BgcolorTwo']);
echo "\n"; echo "\n";
?> ?>
<tr> <tr>
@@ -419,7 +419,7 @@ else if (!defined('PMA_IDX_INCLUDED')
if ($idx_cnt > 0) { if ($idx_cnt > 0) {
?> ?>
<table border="<?php echo $cfgBorder; ?>"> <table border="<?php echo $cfg['Border']; ?>">
<tr> <tr>
<th><?php echo $strKeyname; ?></th> <th><?php echo $strKeyname; ?></th>
<th><?php echo $strType; ?></th> <th><?php echo $strType; ?></th>
@@ -430,7 +430,7 @@ else if (!defined('PMA_IDX_INCLUDED')
<?php <?php
echo "\n"; echo "\n";
while (list($index_no, $index_name) = each($indexes)) { while (list($index_no, $index_name) = each($indexes)) {
$cell_bgd = (($index_no % 2) ? $cfgBgcolorOne : $cfgBgcolorTwo); $cell_bgd = (($index_no % 2) ? $cfg['BgcolorOne'] : $cfg['BgcolorTwo']);
$index_td = ' <td bgcolor="' . $cell_bgd . '" rowspan="' . count($indexes_info[$index_name]['Sequences']) . '">' . "\n"; $index_td = ' <td bgcolor="' . $cell_bgd . '" rowspan="' . count($indexes_info[$index_name]['Sequences']) . '">' . "\n";
echo ' <tr>' . "\n"; echo ' <tr>' . "\n";
echo $index_td echo $index_td