From 3940f28ab159fef62b5ae57141a8aa36fe4f43ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Wed, 23 May 2012 13:37:40 +0200 Subject: [PATCH] Fix indentation --- libraries/display_tbl.lib.php | 1040 ++++++++++++++++----------------- 1 file changed, 520 insertions(+), 520 deletions(-) diff --git a/libraries/display_tbl.lib.php b/libraries/display_tbl.lib.php index ded41daa72..331dd86168 100644 --- a/libraries/display_tbl.lib.php +++ b/libraries/display_tbl.lib.php @@ -55,7 +55,7 @@ require_once './libraries/Index.class.php'; */ function PMA_setDisplayMode(&$the_disp_mode, &$the_total) { - + global $db, $table; global $unlim_num_rows, $fields_meta; global $err_url; @@ -102,7 +102,7 @@ function PMA_setDisplayMode(&$the_disp_mode, &$the_total) $do_display['text_btn'] = (string) '0'; } $do_display['pview_lnk'] = (string) '1'; - + } elseif ($GLOBALS['is_show']) { // 2.2 Statement is a "SHOW..." /** @@ -198,7 +198,7 @@ function PMA_setDisplayMode(&$the_disp_mode, &$the_total) $the_disp_mode = join('', $do_display); return $do_display; - + } // end of the 'PMA_setDisplayMode()' function @@ -245,7 +245,7 @@ function PMA_isSelect() function PMA_getTableNavigationButton($caption, $title, $pos, $html_sql_query, $onsubmit = '', $input_for_real_end = '', $onclick = '' ) { - + global $db, $table, $goto; $caption_output = ''; @@ -253,15 +253,15 @@ function PMA_getTableNavigationButton($caption, $title, $pos, $html_sql_query, if ($GLOBALS['cfg']['NavigationBarIconic']) { $caption_output .= $caption; } - + // for false or 'both' if (($GLOBALS['cfg']['NavigationBarIconic'] === false) || ($GLOBALS['cfg']['NavigationBarIconic'] === 'both') ) { $caption_output .= ' ' . $title; } - $title_output = ' title="' . $title . '"'; - + $title_output = ' title="' . $title . '"'; + return '' . '
' . PMA_generate_common_hidden_inputs($db, $table) @@ -274,7 +274,7 @@ function PMA_getTableNavigationButton($caption, $title, $pos, $html_sql_query, . 'value="' . $caption_output . '" ' . $title_output . $onclick . ' />' . '
' . ''; - + } // end function PMA_getTableNavigationButton() @@ -305,12 +305,12 @@ function PMA_getTableNavigationButton($caption, $title, $pos, $html_sql_query, function PMA_getTableNavigation($pos_next, $pos_prev, $sql_query, $id_for_direction_dropdown ) { - + global $db, $table, $goto; global $num_rows, $unlim_num_rows; global $is_innodb; global $showtable; - + $table_navigation_html = ''; // here, using htmlentities() would cause problems if the query @@ -327,12 +327,12 @@ function PMA_getTableNavigation($pos_next, $pos_prev, $sql_query, $table_navigation_html .= '' . '' . ''; - + // Move to the beginning or to the previous page if ($_SESSION['tmp_user_values']['pos'] && ($_SESSION['tmp_user_values']['max_rows'] != 'all') ) { - + $table_navigation_html .= PMA_getMoveBackwardButtonsForTableNavigation( $html_sql_query, $pos_prev ); @@ -343,41 +343,41 @@ function PMA_getTableNavigation($pos_next, $pos_prev, $sql_query, //page redirection // (unless we are showing all records) if ($_SESSION['tmp_user_values']['max_rows'] != 'all') { //if1 - + $pageNow = @floor( $_SESSION['tmp_user_values']['pos'] / $_SESSION['tmp_user_values']['max_rows'] ) + 1; - + $nbTotalPage = @ceil( $unlim_num_rows / $_SESSION['tmp_user_values']['max_rows'] ); if ($nbTotalPage > 1) { //if2 - - $table_navigation_html .= ''; - } //_if2 + . ''; + } //_if2 } //_if1 // Display the "Show all" button if allowed @@ -385,11 +385,11 @@ function PMA_getTableNavigation($pos_next, $pos_prev, $sql_query, && ($GLOBALS['cfg']['ShowAll'] || ($GLOBALS['cfg']['MaxRows'] * 5 >= $unlim_num_rows)) ) { - + $table_navigation_html .= PMA_getShowAllButtonForTableNavigation( $db, $table, $html_sql_query, $goto ); - + } // end show all // Move to the next page or to the last one @@ -398,7 +398,7 @@ function PMA_getTableNavigation($pos_next, $pos_prev, $sql_query, && ($num_rows >= $_SESSION['tmp_user_values']['max_rows']) && ($_SESSION['tmp_user_values']['max_rows'] != 'all') ) { - + $table_navigation_html .= PMA_getMoveFarwardButtonsForTableNavigation( $html_sql_query, $pos_next, $is_innodb, $unlim_num_rows, $num_rows @@ -410,7 +410,7 @@ function PMA_getTableNavigation($pos_next, $pos_prev, $sql_query, if ($nbTotalPage > 1) { $table_navigation_html .= ''; } - + $table_navigation_html .= '' . '' . ''; - + return $table_navigation_html; } // end of the 'PMA_getTableNavigation()' function @@ -467,40 +467,40 @@ function PMA_getTableNavigation($pos_next, $pos_prev, $sql_query, /** * Prepare move backward buttons - previous and first - * + * * @param string $html_sql_query the sql encoded by html special characters * @param integer $pos_prev the offset for the "previous" page - * + * * @return string html content - * + * * @see PMA_getTableNavigation() */ function PMA_getMoveBackwardButtonsForTableNavigation($html_sql_query, $pos_prev) -{ +{ return PMA_getTableNavigationButton( '<<', _pgettext('First page', 'Begin'), 0, $html_sql_query ) . PMA_getTableNavigationButton( '<', _pgettext('Previous page', 'Previous'), $pos_prev, $html_sql_query - ); + ); } /** * Prepare Show All button for table navigation - * + * * @param string $db the database name * @param string $table the table name * @param string $html_sql_query the sql encoded by html special characters * @param string $goto the URL to go back in case of errors - * + * * @return string html content - * + * * @see PMA_getTableNavigation() */ function PMA_getShowAllButtonForTableNavigation($db, $table, $html_sql_query, $goto) -{ +{ return "\n" . '' . '' @@ -511,34 +511,34 @@ function PMA_getShowAllButtonForTableNavigation($db, $table, $html_sql_query, $g . '' . '' . '' - . ''; + . ''; } /** * Prepare move farward buttons - next and last - * + * * @param string $html_sql_query the sql encoded by html special characters * @param integer $pos_prev the offset for the "previous" page * @param boolean $is_innodb whether its InnoDB or not * @param integer $unlim_num_rows the total number of rows returned by the * @param integer $num_rows the total number of rows returned by the - * + * * @return string $buttons_html html content - * + * * @see PMA_getTableNavigation() */ function PMA_getMoveFarwardButtonsForTableNavigation( $html_sql_query, $pos_next, $is_innodb, $unlim_num_rows, $num_rows ) { - + // display the Next button $buttons_html = PMA_getTableNavigationButton( - '>', - _pgettext('Next page', 'Next'), - $pos_next, - $html_sql_query - ); + '>', + _pgettext('Next page', 'Next'), + $pos_next, + $html_sql_query + ); // prepare some options for the End button if ($is_innodb && $unlim_num_rows > $GLOBALS['cfg']['MaxExactCount']) { @@ -565,33 +565,33 @@ function PMA_getMoveFarwardButtonsForTableNavigation( * $_SESSION['tmp_user_values']['max_rows']), $html_sql_query, $onsubmit, $input_for_real_end, $onclick ); - + return $buttons_html; - + } /** * Prepare feilds followed by Show button for table navigation * Start row, Number of rows, Headers every - * + * * @param string $html_sql_query the sql encoded by html special characters * @param string $goto the URL to go back in case of errors * @param integer $pos_next the offset for the "next" page * @param integer $unlim_num_rows the total number of rows returned by the * @param string $id_for_direction_dropdown the id for the direction dropdown - * + * * @return string $additional_fields_html html content - * + * * @see PMA_getTableNavigation() */ function PMA_getAdditionalFieldsForTableNavigation( $html_sql_query, $goto, $pos_next, $unlim_num_rows, $id_for_direction_dropdown ) { - + $additional_fields_html = ''; - + $additional_fields_html .= '' . '' @@ -608,7 +608,7 @@ function PMA_getAdditionalFieldsForTableNavigation( ? $_SESSION['tmp_user_values']['max_rows'] : $GLOBALS['cfg']['MaxRows']) . '" class="textfield" onfocus="this.select()" />'; - + if ($GLOBALS['cfg']['ShowDisplayDirection']) { // Display mode (horizontal/vertical and repeat headers) $additional_fields_html .= __('Mode') . ': ' . "\n"; @@ -617,7 +617,7 @@ function PMA_getAdditionalFieldsForTableNavigation( 'horizontalflipped' => __('horizontal (rotated headers)'), 'vertical' => __('vertical') ); - + $additional_fields_html .= PMA_getDropdown( 'disp_direction', $choices, $_SESSION['tmp_user_values']['disp_direction'], @@ -632,9 +632,9 @@ function PMA_getAdditionalFieldsForTableNavigation( . '" class="textfield" /> ' . __('rows') . "\n"; - + return $additional_fields_html; - + } @@ -688,7 +688,7 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, if ($analyzed_sql == '') { $analyzed_sql = array(); } - + $directionCondition = ($direction == 'horizontal') || ($direction == 'horizontalflipped'); @@ -722,7 +722,7 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, $table_headers_html .= PMA_getSortByKeyDropDown( $db, $table, $indexes, $sort_expression, $unsorted_sql_query - ); + ); } } } @@ -733,10 +733,10 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, . '
' . PMA_generate_common_hidden_inputs($db, $table) . '
'; - + // Output data needed for column reordering and show/hide column - if (PMA_isSelect()) { - $table_headers_html .= PMA_getDataForResettingColumnOrder(); + if (PMA_isSelect()) { + $table_headers_html .= PMA_getDataForResettingColumnOrder(); } $vertical_display['emptypre'] = 0; @@ -745,30 +745,30 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, // Display options (if we are not in print view) if (! (isset($GLOBALS['printview']) && ($GLOBALS['printview'] == '1'))) { - + $table_headers_html .= PMA_getOptionsBlock($db, $table, $sql_query, $goto); - + // prepare full/partial text button or link $full_or_partial_text_link = PMA_getFullOrPartialTextButtonOrLink( $db, $table, $sql_query, $goto - ); + ); } // Start of form for multi-rows edit/delete/export $table_headers_html .= PMA_getFormForMultiRowOperations( $db, $table, $is_display['del_lnk'] ); - + // 1. Displays the full/partial text button (part 1)... if ($directionCondition) { - + $table_headers_html .= '' . "\n"; - + $colspan = (($is_display['edit_lnk'] != 'nn') && ($is_display['del_lnk'] != 'nn')) ? ' colspan="4"' : ''; - + } else { $rowspan = (($is_display['edit_lnk'] != 'nn') && ($is_display['del_lnk'] != 'nn')) @@ -780,24 +780,24 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, if ((($is_display['edit_lnk'] == 'nn') && ($is_display['del_lnk'] == 'nn')) && ($is_display['text_btn'] == '1') ) { - + $vertical_display['emptypre'] = (($is_display['edit_lnk'] != 'nn') && ($is_display['del_lnk'] != 'nn')) ? 4 : 0; - + if ($directionCondition) { - + $table_headers_html .= '' . '' . ''; - + // end horizontal/horizontalflipped mode } else { - + $table_headers_html .= '' . '' . ''; - + } // end vertical mode } elseif ((($GLOBALS['cfg']['RowActionLinks'] == 'left') @@ -809,15 +809,15 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, $vertical_display['emptypre'] = (($is_display['edit_lnk'] != 'nn') && ($is_display['del_lnk'] != 'nn')) ? 4 : 0; - + if ($directionCondition) { - + $table_headers_html .= '' - . $full_or_partial_text_link . ''; + . $full_or_partial_text_link . ''; // end horizontal/horizontalflipped mode - + } else { - + $vertical_display['textbtn'] = ' ' . "\n" . ' ' . "\n" @@ -832,11 +832,11 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, $vertical_display['emptypre'] = (($is_display['edit_lnk'] != 'nn') && ($is_display['del_lnk'] != 'nn')) ? 4 : 0; - + if ($directionCondition) { - + $table_headers_html .= ''; - + // end horizontal/horizontalfipped mode } else { $vertical_display['textbtn'] = ' ' . "\n"; @@ -900,22 +900,22 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, } list($col_order, $col_visib) = PMA_getColumnParams(); - + for ($j = 0; $j < $fields_cnt; $j++) { - + // assign $i with appropriate column order $i = $col_order ? $col_order[$j] : $j; - + // See if this column should get highlight because it's used in the // where-query. $condition_field = (isset($highlight_columns[$fields_meta[$i]->name]) || isset($highlight_columns[PMA_backquote($fields_meta[$i]->name)])) ? true : false; - + // 2.0 Prepare comment-HTML-wrappers for each row, if defined/enabled. $comments = PMA_getCommentForRow($comments_map, $fields_meta[$i]); - + // 2.1 Results can be sorted if ($is_display['sort_lnk'] == '1') { @@ -924,7 +924,7 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, // isn't aliased, or in queries like // SELECT `1`.`master_field` , `2`.`master_field` // FROM `PMA_relation` AS `1` , `PMA_relation` AS `2` - + $sort_tbl = (isset($fields_meta[$i]->table) && strlen($fields_meta[$i]->table)) ? PMA_backquote($fields_meta[$i]->table) . '.' @@ -942,7 +942,7 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, $name_to_use_in_sort = $fields_meta[$i]->orgname; $is_orgname = true; } - + // $name_to_use_in_sort might contain a space due to // formatting of function expressions like "COUNT(name )" // so we remove the space in this situation @@ -952,7 +952,7 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, $sort_expression, $sort_expression_nodirection, $sort_tbl, $name_to_use_in_sort ); - + // 2.1.3 Check the field name for a bracket. // If it contains one, it's probably a function column // like 'COUNT(`field`)' @@ -968,12 +968,12 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, unset($is_orgname); // 2.1.4 Do define the sorting URL - + list($sort_order, $order_img) = PMA_getSortingUrlParams( $is_in_sort, $sort_direction, $fields_meta[$i], $sort_order, $i ); - + if (preg_match('@(.*)([[:space:]](LIMIT (.*)|PROCEDURE (.*)|FOR UPDATE|' . 'LOCK IN SHARE MODE))@is', $unsorted_sql_query, $regs3) ) { @@ -981,7 +981,7 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, } else { $sorted_sql_query = $unsorted_sql_query . $sort_order; } - + $_url_params = array( 'db' => $db, 'table' => $table, @@ -991,18 +991,18 @@ function PMA_getTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, $order_url = 'sql.php' . PMA_generate_common_url($_url_params); // 2.1.5 Displays the sorting URL - // enable sort order swapping for image + // enable sort order swapping for image $order_link = PMA_getSortOrderLink( $order_img, $i, $direction, $fields_meta[$i], $order_url ); - if ($directionCondition) { + if ($directionCondition) { $table_headers_html .= PMA_getDraggableClassForSortableColumns( $col_visib, $col_visib[$j], $condition_field, $direction, $fields_meta[$i], $order_link, $comments - ); + ); } - + $vertical_display['desc'][] = ' ' . $full_or_partial_text_link . ''; - + // end horizontal/horizontalflipped mode } else { $vertical_display['textbtn'] = ' '; - + // end horizontal/horizontalflipped mode } else { $vertical_display['textbtn'] = ' ' . "\n"; } // end vertical mode } - if ($directionCondition) { + if ($directionCondition) { $table_headers_html .= '' - . ''; + . ''; } - + return $table_headers_html; - + } // end of the 'PMA_getTableHeaders()' function /** * Prepare sort by key dropdown - html code segment - * + * * @param string $db the database name * @param string $table the table name * @param array $indexes the indexes of the table for sort criteria * @param string $sort_expression the sort expression * @param string $unsorted_sql_query the unsorted sql query - * + * * @return string $drop_down_html html content - * + * * @see PMA_getTableHeaders() */ function PMA_getSortByKeyDropDown( $db, $table, $indexes, $sort_expression, $unsorted_sql_query ) { - + $drop_down_html = ''; - + $drop_down_html .= '
' . "\n" . PMA_generate_common_hidden_inputs($db, $table) . __('Sort by key') @@ -1168,24 +1168,24 @@ function PMA_getSortByKeyDropDown( . '' . '' . "\n" . '
' . "\n"; - + return $drop_down_html; - + } /** * Prepare data for column restoring and show/hide - * + * * @return string $data_html html content - * + * * @see PMA_getTableHeaders() */ function PMA_getDataForResettingColumnOrder() { - + $data_html = ''; - + // generate the column order, if it is set $pmatable = new PMA_Table($GLOBALS['table'], $GLOBALS['db']); $col_order = $pmatable->getUiProp(PMA_Table::PROP_COLUMN_ORDER); @@ -1209,29 +1209,29 @@ function PMA_getDataForResettingColumnOrder() $GLOBALS['db'], $GLOBALS['table'], 'Create_time' ) . '" />'; } - + return $data_html; - + } /** * Prepare option fields block - * + * * @param string $db the database name * @param string $table the table name * @param string $sql_query the SQL query * @param string $goto the URL to go back in case of errors - * + * * @return string $options_html html content - * + * * @see PMA_getTableHeaders() */ function PMA_getOptionsBlock($db, $table, $sql_query, $goto) { - + $options_html = ''; - + $options_html .= '
'; - + if ($GLOBALS['cfgRelation']['relwork'] && $GLOBALS['cfgRelation']['displaywork'] ) { @@ -1332,27 +1332,27 @@ function PMA_getOptionsBlock($db, $table, $sql_query, $goto) . '' . '' . '
'; - + return $options_html; - + } /** * Get full/partial text button or link - * + * * @param string $db the database name * @param string $table the table name * @param string $sql_query the SQL query * @param string $goto the URL to go back in case of errors - * + * * @return string html content - * + * * @see PMA_getTableHeaders() */ function PMA_getFullOrPartialTextButtonOrLink($db, $table, $sql_query, $goto) { - + $url_params_full_text = array( 'db' => $db, 'table' => $table, @@ -1375,37 +1375,37 @@ function PMA_getFullOrPartialTextButtonOrLink($db, $table, $sql_query, $goto) $tmp_image = ''
                  . $tmp_txt . ''; $tmp_url = 'sql.php' . PMA_generate_common_url($url_params_full_text); - + return PMA_linkOrButton($tmp_url, $tmp_image, array(), false); - + } /** * Prepare html form for multi row operations - * + * * @param string $db the database name * @param string $table the table name * @param string $del_lnk the delete link of current row - * + * * @return string $form_html html content - * + * * @see PMA_getTableHeaders() */ function PMA_getFormForMultiRowOperations($db, $table, $del_lnk) { - + $form_html = ''; - + if (($del_lnk == 'dr') || ($del_lnk == 'kp')) { - + $form_html .= '
' . "\n"; @@ -1416,20 +1416,20 @@ function PMA_getFormForMultiRowOperations($db, $table, $del_lnk) $form_html .= ' ajax'; } $form_html .= '">' . "\n"; - + return $form_html; - + } /** * Get comment for row - * + * * @param array $comments_map comments array * @param array $fields_meta set of field properties - * + * * @return string $comment html content - * + * * @see PMA_getTableHeaders() */ function PMA_getCommentForRow($comments_map, $fields_meta) @@ -1445,27 +1445,27 @@ function PMA_getCommentForRow($comments_map, $fields_meta) ) . ''; } - return $comments; + return $comments; } /** * Check whether the column is sorted - * + * * @param string $sort_expression sort expression * @param string $sort_expression_nodirection sort expression without direction * @param string $sort_tbl the table name * @param string $name_to_use_in_sort the sorting column name - * + * * @return boolean $is_in_sort the column sorted or not - * + * * @see PMA_getTableHeaders() */ function PMA_isInSorted( $sort_expression, $sort_expression_nodirection, $sort_tbl, $name_to_use_in_sort ) { - + if (empty($sort_expression)) { $is_in_sort = false; } else { @@ -1497,29 +1497,29 @@ function PMA_isInSorted( $is_in_sort = true; } } - + return $is_in_sort; - + } /** * Get sort url paramaeters - sort order and order image - * + * * @param boolean $is_in_sort the column sorted or not * @param string $sort_direction the sort direction * @param array $fields_meta set of field properties * @param string $sort_order the sorting order * @param integer $column_index the index of the column - * + * * @return array 2 element array - $sort_order, $order_img - * + * * @see PMA_getTableHeaders() */ function PMA_getSortingUrlParams( $is_in_sort, $sort_direction, $fields_meta, $sort_order, $column_index ) { - + if (! $is_in_sort) { // patch #455484 ("Smart" order) @@ -1561,31 +1561,31 @@ function PMA_getSortingUrlParams( array('class' => "soimg$column_index hide", 'title' => '') ); } - + return array($sort_order, $order_img); - + } /** * Get sort order link - * + * * @param string $order_img the sort order image * @param integer $col_index the index of the column * @param string $direction the display direction * @param array $fields_meta set of field properties * @param string $order_url the url for sort - * + * * @return string the sort order link - * + * * @see PMA_getTableHeaders() */ function PMA_getSortOrderLink( $order_img, $col_index, $direction, $fields_meta, $order_url ) { - + $order_link_params = array(); - + if (isset($order_img) && ($order_img != '')) { if (strstr($order_img, 'asc')) { $order_link_params['onmouseover'] = "$('.soimg$col_index').toggle()"; @@ -1595,11 +1595,11 @@ function PMA_getSortOrderLink( $order_link_params['onmouseout'] = "$('.soimg$col_index').toggle()"; } } - + if ($GLOBALS['cfg']['HeaderFlipType'] == 'auto') { $GLOBALS['cfg']['HeaderFlipType'] - = (PMA_USR_BROWSER_AGENT == 'IE') ? 'css' : 'fake'; + = (PMA_USR_BROWSER_AGENT == 'IE') ? 'css' : 'fake'; } if ($direction == 'horizontalflipped' @@ -1622,13 +1622,13 @@ function PMA_getSortOrderLink( $order_url, $order_link_content . $order_img, $order_link_params, false, true ); - + } /** * Prepare columns to draggable effect for sortable columns - * + * * @param boolean $col_visib the column is visible (false) * array the column is not visible (string array) * @param string $col_visib_j element of $col_visib array @@ -1637,16 +1637,16 @@ function PMA_getSortOrderLink( * @param array $fields_meta set of field properties * @param string $order_link the order link * @param string $comments the comment for the column - * + * * @return string $draggable_html html content - * + * * @see PMA_getTableHeaders() */ function PMA_getDraggableClassForSortableColumns( $col_visib, $col_visib_j, $condition_field, $direction, $fields_meta, $order_link, $comments ) { - + $draggable_html = 'name) . '">' . $order_link . $comments . ''; - + return $draggable_html; - + } /** * Prepare columns to draggable effect for non sortable columns - * + * * @param boolean $col_visib the column is visible (false) * array the column is not visible (string array) * @param string $col_visib_j element of $col_visib array @@ -1692,16 +1692,16 @@ function PMA_getDraggableClassForSortableColumns( * @param string $direction the display direction * @param array $fields_meta set of field properties * @param string $comments the comment for the column - * + * * @return string $draggable_html html content - * + * * @see PMA_getTableHeaders() */ function PMA_getDraggableClassForNonSortableColumns( $col_visib, $col_visib_j, $condition_field, $direction, $fields_meta, $comments ) { - + $draggable_html = ''; - + return $draggable_html; - + } @@ -1821,7 +1821,7 @@ function PMA_buildEmptyDisplay($class, $condition_field, $meta, $align = '') function PMA_addClass($class, $condition_field, $meta, $nowrap, $is_field_truncated = false, $transform_function = '', $default_function = '' ) { - + // Define classes to be added to this data field based on the type of data $enum_class = ''; if (strpos($meta->flags, 'enum') !== false) { @@ -1847,7 +1847,7 @@ function PMA_addClass($class, $condition_field, $meta, $nowrap, . ' ' . ($is_field_truncated ? ' truncated' : '') . ($transform_function != $default_function ? ' transformed' : '') . $enum_class . $set_class . $bit_class . $mime_type_class; - + } @@ -1880,7 +1880,7 @@ function PMA_addClass($class, $condition_field, $meta, $nowrap, */ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) { - + global $db, $table, $goto; global $sql_query, $fields_meta, $fields_cnt; global $vertical_display, $highlight_columns; @@ -1892,11 +1892,11 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) // query without conditions to shorten URLs when needed, 200 is just // guess, it should depend on remaining URL length $url_sql_query = PMA_getUrlSqlQuery($analyzed_sql, $sql_query); - + if (! is_array($map)) { $map = array(); } - + $row_no = 0; $vertical_display['edit'] = array(); $vertical_display['copy'] = array(); @@ -1924,9 +1924,9 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) $odd_row = true; $directionCondition = ($_SESSION['tmp_user_values']['disp_direction'] == 'horizontal') || ($_SESSION['tmp_user_values']['disp_direction'] == 'horizontalflipped'); - + while ($row = PMA_DBI_fetch_row($dt_result)) { - + // "vertical display" mode stuff $table_body_html .= PMA_getVerticalDisplaySupportSegments( $vertical_display, $row_no, $directionCondition @@ -1966,24 +1966,24 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) // 1.2.1 Modify link(s) if ($is_display['edit_lnk'] == 'ur') { // update row case - + list($edit_url, $copy_url, $edit_str, $copy_str, $edit_anchor_class) = PMA_getModifiedLinks( $db, $table, $where_clause, $clause_is_unique, $url_sql_query ); - + } // end if (1.2.1) // 1.2.2 Delete/Kill link(s) if (($is_display['del_lnk'] == 'dr') || ($is_display['del_lnk'] == 'kp')) { - + list($del_query, $del_url, $del_str, $js_conf) = PMA_getDeleteAndKillLinks( $db, $table, $where_clause, $clause_is_unique, $url_sql_query, $goto, $is_display['del_lnk'] ); - + } // end if (1.2.2) // 1.3 Displays the links at left if required @@ -1991,32 +1991,32 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) || ($GLOBALS['cfg']['RowActionLinks'] == 'both')) && $directionCondition ) { - + $table_body_html .= PMA_getPlacedLinks( 'left', $del_url, $is_display, $row_no, $where_clause, $where_clause_html, $condition_array, $del_query, 'l', $edit_url, $copy_url, $edit_anchor_class, $edit_str, $copy_str, $del_str, $js_conf - ); - + ); + } elseif (($GLOBALS['cfg']['RowActionLinks'] == 'none') && $directionCondition ) { - + $table_body_html .= PMA_getPlacedLinks( 'none', $del_url, $is_display, $row_no, $where_clause, $where_clause_html, $condition_array, $del_query, 'l', $edit_url, $copy_url, $edit_anchor_class, $edit_str, $copy_str, $del_str, $js_conf ); - + } // end if (1.3) } // end if (1) // 2. Displays the rows' values for ($j = 0; $j < $fields_cnt; ++$j) { - + // assign $i with appropriate column order $i = $col_order ? $col_order[$j] : $j; @@ -2028,10 +2028,10 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) && ($_SESSION['tmp_user_values']['disp_direction'] != 'vertical')) ? 'hide' : ''; - + // handle datetime-related class, for grid editing $field_type_class = PMA_getClassForDateTimeRelatedFields($meta->type); - + $pointer = $i; $is_field_truncated = false; //If the previous column had blob data, we need to reset the class @@ -2057,18 +2057,18 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) if ($GLOBALS['cfgRelation']['mimework'] && $GLOBALS['cfg']['BrowseMIME'] ) { - + if (isset($GLOBALS['mime_map'][$meta->name]['mimetype']) && isset($GLOBALS['mime_map'][$meta->name]['transformation']) && !empty($GLOBALS['mime_map'][$meta->name]['transformation']) ) { - + $include_file = PMA_securePath( $GLOBALS['mime_map'][$meta->name]['transformation'] ); - + if (file_exists('./libraries/transformations/' . $include_file)) { - + $transformfunction_name = str_replace( '.inc.php', '', $GLOBALS['mime_map'][$meta->name]['transformation'] @@ -2077,16 +2077,16 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) include_once './libraries/transformations/' . $include_file; if (function_exists('PMA_transformation_' . $transformfunction_name)) { - + $transform_function = 'PMA_transformation_' . $transformfunction_name; - + $transform_options = PMA_transformation_getOptions( isset($GLOBALS['mime_map'][$meta->name]['transformation_options']) ? $GLOBALS['mime_map'][$meta->name]['transformation_options'] : '' ); - + $meta->mimetype = str_replace( '_', '/', $GLOBALS['mime_map'][$meta->name]['mimetype'] @@ -2116,7 +2116,7 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) // with self-join queries, for example), using $meta->name // will show both fields NULL even if only one is NULL, // so use the $pointer - + $vertical_display['data'][$row_no][$i] = PMA_getDataCellForNumericFeilds( $row[$i], $class, $condition_field, $meta, @@ -2126,25 +2126,25 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) // b l o b } elseif (stristr($meta->type, 'BLOB')) { - + // PMA_mysql_fetch_fields returns BLOB in place of // TEXT fields type so we have to ensure it's really a BLOB $field_flags = PMA_DBI_field_flags($dt_result, $i); - + $vertical_display['data'][$row_no][$i] = PMA_getDataCellForBlobField( $row[$i], $class, $meta, $_url_params, $field_flags, $transform_function, $default_function, $transform_options, $condition_field, $is_field_truncated ); - + // g e o m e t r y } elseif ($meta->type == 'geometry') { // Remove 'grid_edit' from $class as we do not allow to inline-edit // geometry data. $class = str_replace('grid_edit', '', $class); - + $vertical_display['data'][$row_no][$i] = PMA_getDataCellForGeometryFields( $row[$i], $class, $meta, $map, $_url_params, @@ -2154,7 +2154,7 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) // n o t n u m e r i c a n d n o t B L O B } else { - + $vertical_display['data'][$row_no][$i] = PMA_getDataCellForNonNumericAndNonBlobFields( $row[$i], $class, $meta, $map, $_url_params, @@ -2162,7 +2162,7 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) $transform_options, $is_field_truncated, $analyzed_sql, $dt_result, $i ); - + } // output stored cell @@ -2184,14 +2184,14 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) || ($GLOBALS['cfg']['RowActionLinks'] == 'both')) && $directionCondition ) { - + $table_body_html .= PMA_getPlacedLinks( 'right', $del_url, $is_display, $row_no, $where_clause, $where_clause_html, $condition_array, $del_query, 'r', $edit_url, $copy_url, $edit_anchor_class, $edit_str, $copy_str, $del_str, $js_conf ); - + } // end if (3) if ($directionCondition) { @@ -2206,30 +2206,30 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) $vertical_display['delete'][$row_no] = ''; $vertical_display['row_delete'][$row_no] = ''; } - + $vertical_class = ' row_' . $row_no; if ($GLOBALS['cfg']['BrowsePointerEnable'] == true) { $vertical_class .= ' vpointer'; } - + if ($GLOBALS['cfg']['BrowseMarkerEnable'] == true) { $vertical_class .= ' vmarker'; } if (!empty($del_url) && ($is_display['del_lnk'] != 'kp')) { - + $vertical_display['row_delete'][$row_no] .= PMA_getCheckboxForMultiRowSubmissions( $del_url, $is_display, $row_no, $where_clause_html, $condition_array, $del_query, '[%_PMA_CHECKBOX_DIR_%]', $alternating_color_class . $vertical_class ); - + } else { unset($vertical_display['row_delete'][$row_no]); } if (isset($edit_url)) { - + $vertical_display['edit'][$row_no] .= PMA_getEditLink( $edit_url, $alternating_color_class . ' ' . $edit_anchor_class @@ -2237,60 +2237,60 @@ function PMA_getTableBody(&$dt_result, &$is_display, $map, $analyzed_sql) $where_clause, $where_clause_html ); - + } else { unset($vertical_display['edit'][$row_no]); } if (isset($copy_url)) { - + $vertical_display['copy'][$row_no] .= PMA_getCopyLink( $copy_url, $copy_str, $where_clause, $where_clause_html, $alternating_color_class . $vertical_class ); - + } else { unset($vertical_display['copy'][$row_no]); } if (isset($del_url)) { - + if (! isset($js_conf)) { $js_conf = ''; } - + $vertical_display['delete'][$row_no] .= PMA_getDeleteLink( $del_url, $del_str, $js_conf, $alternating_color_class . $vertical_class ); - + } else { unset($vertical_display['delete'][$row_no]); } - $table_body_html .= $directionCondition ? "\n" : ''; + $table_body_html .= $directionCondition ? "\n" : ''; $row_no++; - + } // end while - + return $table_body_html; - + } // end of the 'PMA_getTableBody()' function /** * Get url sql query without conditions to shorten URLs - * + * * @param array $analyzed_sql analyzed query * @param string $sql_query the SQL query - * + * * @return string $url_sql analyzed sql query - * + * * @see PMA_getTableBody() */ function PMA_getUrlSqlQuery($analyzed_sql, $sql_query) { - + if (isset($analyzed_sql) && isset($analyzed_sql[0]) && isset($analyzed_sql[0]['querytype']) @@ -2302,29 +2302,29 @@ function PMA_getUrlSqlQuery($analyzed_sql, $sql_query) if (isset($analyzed_sql[0]['queryflags']['distinct'])) { $url_sql_query .= ' DISTINCT '; } - + $url_sql_query .= $analyzed_sql[0]['select_expr_clause']; if (!empty($analyzed_sql[0]['from_clause'])) { $url_sql_query .= ' FROM ' . $analyzed_sql[0]['from_clause']; } - + return $url_sql_query; } - + return $sql_query; - + } /** * Get column order and column visibility - * + * * @return array 2 element array - $col_order, $col_visib - * + * * @see PMA_getTableBody() */ function PMA_getColumnParams() -{ +{ if (PMA_isSelect()) { $pmatable = new PMA_Table($GLOBALS['table'], $GLOBALS['db']); $col_order = $pmatable->getUiProp(PMA_Table::PROP_COLUMN_ORDER); @@ -2333,29 +2333,29 @@ function PMA_getColumnParams() $col_order = false; $col_visib = false; } - - return array($col_order, $col_visib); + + return array($col_order, $col_visib); } /** * Prepare vertical display mode necessay HTML stuff - * + * * @param array $vertical_display informations used with vertical * display mode * @param integer $row_no the index of current row * @param boolean $directionCondition the directional condition - * + * * @return string $vertical_disp_html html content - * + * * @see PMA_getTableBody() */ function PMA_getVerticalDisplaySupportSegments( $vertical_display, $row_no, $directionCondition ) { - + $support_html = ''; - + if ((($row_no != 0) && ($_SESSION['tmp_user_values']['repeat_cells'] != 0)) && !($row_no % $_SESSION['tmp_user_values']['repeat_cells']) && $directionCondition @@ -2383,30 +2383,30 @@ function PMA_getVerticalDisplaySupportSegments( } $support_html .= '' . "\n"; } // end if - + return $support_html; - + } /** * Get modified links - * + * * @param string $db the database name * @param string $table the table name * @param string $where_clause the where clause of the sql * @param boolean $clause_is_unique the unique condition of clause * @param string $url_sql_query the analyzed sql query - * + * * @return array 5 element array - $edit_url, $copy_url, * $edit_str, $copy_str, $edit_anchor_class - * + * * @see PMA_getTableBody() */ function PMA_getModifiedLinks( $db, $table, $where_clause, $clause_is_unique, $url_sql_query ) { - + $_url_params = array( 'db' => $db, 'table' => $table, @@ -2434,15 +2434,15 @@ function PMA_getModifiedLinks( if ( $clause_is_unique == 0) { $edit_anchor_class .= ' nonunique'; } - + return array($edit_url, $copy_url, $edit_str, $copy_str, $edit_anchor_class); - + } /** * Get delete and kill links - * + * * @param string $db the database name * @param string $table the table name * @param string $where_clause the where clause of the sql @@ -2450,16 +2450,16 @@ function PMA_getModifiedLinks( * @param string $url_sql_query the analyzed sql query * @param string $goto the URL to go back in case of errors * @param string $del_lnk the delete link of current row - * + * * @return array 4 element array - $del_query, * $del_url, $del_str, $js_conf - * + * * @see PMA_getTableBody() */ function PMA_getDeleteAndKillLinks( $db, $table, $where_clause, $clause_is_unique, $url_sql_query, $goto, $del_lnk ) { - + if ($del_lnk == 'dr') { // delete row case $_url_params = array( @@ -2518,15 +2518,15 @@ function PMA_getDeleteAndKillLinks( $js_conf = 'KILL ' . $row[0]; $del_str = PMA_getIcon('b_drop.png', __('Kill')); } - + return array($del_query, $del_url, $del_str, $js_conf); - + } /** * Prepare placed links - * + * * @param string $dir the direction of links should place * @param string $del_url the url for delete row * @param array $is_display which elements to display @@ -2543,17 +2543,17 @@ function PMA_getDeleteAndKillLinks( * @param string $copy_str the label for copy row * @param string $del_str the label for delete row * @param string $js_conf text for the JS confirmation - * + * * @return string html content - * + * * @see PMA_getTableBody() */ function PMA_getPlacedLinks( $dir, $del_url, $is_display, $row_no, $where_clause, $where_clause_html, $condition_array, $del_query, $dir_letter, $edit_url, $copy_url, - $edit_anchor_class, $edit_str, $copy_str, $del_str, $js_conf + $edit_anchor_class, $edit_str, $copy_str, $del_str, $js_conf ) { - + if (! isset($js_conf)) { $js_conf = ''; } @@ -2564,32 +2564,32 @@ function PMA_getPlacedLinks( $del_query, 'l', $edit_url, $copy_url, $edit_anchor_class, $edit_str, $copy_str, $del_str, $js_conf ); - + } /** * Get resetted class for inline edit columns - * + * * @param string $grid_edit_class the class for all editable columns * @param string $not_null_class the class for not null columns * @param string $relation_class the class for relations in a column * @param string $hide_class the class for visibility of a column * @param string $field_type_class the class related to type of the field * @param integer $row_no the row index - * + * * @return string $class the resetted class - * + * * @see PMA_getTableBody() */ function PMA_getResettedClassForInlineEdit( $grid_edit_class, $not_null_class, $relation_class, $hide_class, $field_type_class, $row_no ) { - + $class = 'data ' . $grid_edit_class . ' ' . $not_null_class . ' ' . $relation_class . ' ' . $hide_class . ' ' . $field_type_class; - + if (($_SESSION['tmp_user_values']['disp_direction'] == 'vertical') && (! isset($GLOBALS['printview']) || ($GLOBALS['printview'] != '1')) ) { @@ -2603,23 +2603,23 @@ function PMA_getResettedClassForInlineEdit( $class .= ' vmarker'; } } - + return $class; - + } /** * Get class for datetime related fields - * + * * @param string $type the type of the column field - * + * * @return string $field_type_class the class for the column - * + * * @see PMA_getTableBody() */ function PMA_getClassForDateTimeRelatedFields($type) -{ +{ if ((substr($type, 0, 9) == 'timestamp') || ($type == 'datetime')) { $field_type_class = 'datetimefield'; } else if ($type == 'date') { @@ -2627,33 +2627,33 @@ function PMA_getClassForDateTimeRelatedFields($type) } else { $field_type_class = ''; } - return $field_type_class; + return $field_type_class; } /** * Prepare data cell for numeric type fields - * + * * @param string $column the relavent column in data row * @param string $class the html class for column * @param boolean $condition_field the column should highlighted or not - * @param object $meta the meta-information about this field + * @param object $meta the meta-information about this field * @param array $map the list of relations * @param boolean $is_field_truncated the condition for blob data replacements * @param array $analyzed_sql the analyzed query * @param string $transform_function the name of transformation function - * @param string $default_function the default transformation function + * @param string $default_function the default transformation function * @param string $transform_options the transformation parameters - * + * * @return string $cell the prepared cell, html content - * + * * @see PMA_getTableBody() */ function PMA_getDataCellForNumericFeilds( $column, $class, $condition_field, $meta, $map, $is_field_truncated, - $analyzed_sql, $transform_function, $default_function, $transform_options + $analyzed_sql, $transform_function, $default_function, $transform_options ) { - + if (! isset($column) || is_null($column)) { $cell = PMA_buildNullDisplay( @@ -2679,35 +2679,35 @@ function PMA_getDataCellForNumericFeilds( 'right '.$class, $condition_field, $meta, '' ); } - + return $cell; - + } /** * Get data cell for blob type fields - * + * * @param string $column the relavent column in data row * @param string $class the html class for column * @param object $meta the meta-information about this field * @param array $_url_params the parameters for generate url * @param string $field_flags field flags for column(blob, primary etc) * @param string $transform_function the name of transformation function - * @param string $default_function the default transformation function + * @param string $default_function the default transformation function * @param string $transform_options the transformation parameters * @param boolean $condition_field the column should highlighted or not * @param boolean $is_field_truncated the condition for blob data replacements - * + * * @return string $cell the prepared cell, html content - * + * * @see PMA_getTableBody() */ function PMA_getDataCellForBlobField( - $column, $class, $meta, $_url_params, $field_flags, $transform_function, + $column, $class, $meta, $_url_params, $field_flags, $transform_function, $default_function, $transform_options, $condition_field, $is_field_truncated ) { - + if (stristr($field_flags, 'BINARY')) { // remove 'grid_edit' from $class as we can't edit binary data. @@ -2765,15 +2765,15 @@ function PMA_getDataCellForBlobField( $cell = PMA_buildEmptyDisplay($class, $condition_field, $meta); } } - + return $cell; - + } /** * Get data cell for geometry type fields - * + * * @param string $column the relavent column in data row * @param string $class the html class for column * @param object $meta the meta-information about this field @@ -2781,21 +2781,21 @@ function PMA_getDataCellForBlobField( * @param array $_url_params the parameters for generate url * @param boolean $condition_field the column should highlighted or not * @param string $transform_function the name of transformation function - * @param string $default_function the default transformation function + * @param string $default_function the default transformation function * @param string $transform_options the transformation parameters * @param boolean $is_field_truncated the condition for blob data replacements * @param array $analyzed_sql the analyzed query - * + * * @return string $cell the prepared data cell, html content - * + * * @see PMA_getTableBody() */ function PMA_getDataCellForGeometryFields( $column, $class, $meta, $map, $_url_params, $condition_field, $transform_function, $default_function, $transform_options, - $is_field_truncated, $analyzed_sql + $is_field_truncated, $analyzed_sql ) { - + if (! isset($column) || is_null($column)) { $cell = PMA_buildNullDisplay($class, $condition_field, $meta); @@ -2886,15 +2886,15 @@ function PMA_getDataCellForGeometryFields( } else { $cell = PMA_buildEmptyDisplay($class, $condition_field, $meta); } - + return $cell; - + } /** * Get data cell for non numeric and non blob type fields - * + * * @param string $column the relavent column in data row * @param string $class the html class for column * @param object $meta the meta-information about this field @@ -2902,16 +2902,16 @@ function PMA_getDataCellForGeometryFields( * @param array $_url_params the parameters for generate url * @param boolean $condition_field the column should highlighted or not * @param string $transform_function the name of transformation function - * @param string $default_function the default transformation function + * @param string $default_function the default transformation function * @param string $transform_options the transformation parameters * @param boolean $is_field_truncated the condition for blob data replacements * @param array $analyzed_sql the analyzed query * @param integer &$dt_result the link id associated to the query * which results have to be displayed * @param integer $col_index the column index - * + * * @return string $cell the prepared data cell, html content - * + * * @see PMA_getTableBody() */ function PMA_getDataCellForNonNumericAndNonBlobFields( @@ -2919,7 +2919,7 @@ function PMA_getDataCellForNonNumericAndNonBlobFields( $transform_function, $default_function, $transform_options, $is_field_truncated, $analyzed_sql, &$dt_result, $col_index ) { - + if (! isset($column) || is_null($column)) { $cell = PMA_buildNullDisplay($class, $condition_field, $meta); @@ -3011,15 +3011,15 @@ function PMA_getDataCellForNonNumericAndNonBlobFields( $transform_function, $default_function, $nowrap, $where_comparison, $transform_options, $is_field_truncated - ); + ); } } else { $cell = PMA_buildEmptyDisplay($class, $condition_field, $meta); } - + return $cell; - + } @@ -3036,9 +3036,9 @@ function PMA_getDataCellForNonNumericAndNonBlobFields( */ function PMA_getVerticalTable() { - + global $vertical_display; - + $vertical_table_html = ''; // Prepares "multi row delete" link at top if required @@ -3047,14 +3047,14 @@ function PMA_getVerticalTable() && ((count($vertical_display['row_delete']) > 0) || !empty($vertical_display['textbtn'])) ) { - + $vertical_table_html .= '' . "\n"; if ($GLOBALS['cfg']['RowActionLinks'] == 'none') { // if we are not showing the RowActionLinks, then we need to show // the Multi-Row-Action checkboxes $vertical_table_html .= '' . "\n"; } - + $vertical_table_html .= $vertical_display['textbtn'] . PMA_getCheckBoxesForMultipleRowOperations( $vertical_display, '_left' @@ -3102,7 +3102,7 @@ function PMA_getVerticalTable() // Prepares data foreach ($vertical_display['desc'] AS $j => $val) { - + // assign appropriate key with current column order $key = $col_order ? $col_order[$j] : $j; @@ -3112,7 +3112,7 @@ function PMA_getVerticalTable() $cell_displayed = 0; foreach ($vertical_display['rowdata'][$key] as $subval) { - + if (($cell_displayed != 0) && ($_SESSION['tmp_user_values']['repeat_cells'] != 0) && !($cell_displayed % $_SESSION['tmp_user_values']['repeat_cells']) @@ -3122,7 +3122,7 @@ function PMA_getVerticalTable() $vertical_table_html .= $subval; $cell_displayed++; - + } // end while $vertical_table_html .= '' . "\n"; @@ -3135,7 +3135,7 @@ function PMA_getVerticalTable() && ((count($vertical_display['row_delete']) > 0) || !empty($vertical_display['textbtn'])) ) { - + $vertical_table_html .= '' . "\n" . $vertical_display['textbtn'] . PMA_getCheckBoxesForMultipleRowOperations( $vertical_display, '_right' @@ -3152,7 +3152,7 @@ function PMA_getVerticalTable() ) { $vertical_table_html .= PMA_getOperationLinksForVerticleTable( $vertical_display, 'edit' - ); + ); } // end if // Prepares "copy" link at bottom if required @@ -3180,64 +3180,64 @@ function PMA_getVerticalTable() } return $vertical_table_html; - + } // end of the 'PMA_getVerticalTable' function /** * Prepare edit, copy and delete links for verticle table - * + * * @param array $vertical_display the information to display * @param string $operation edit/copy/delete - * + * * @return string $links_html html content - * + * * @see PMA_getVerticalTable() */ function PMA_getOperationLinksForVerticleTable($vertical_display, $operation) { - + $link_html = '' . "\n"; - + if (! is_array($vertical_display['row_delete'])) { - - if (($operation == 'edit') || ($operation == 'copy')) { + + if (($operation == 'edit') || ($operation == 'copy')) { $link_html .= $vertical_display['textbtn']; - + } elseif ($operation == 'delete') { - + if (! is_array($vertical_display['edit'])) { $link_html .= $vertical_display['textbtn']; } - } + } } foreach ($vertical_display[$operation] as $val) { $link_html .= $val; } // end while - + $link_html .= '' . "\n"; - + return $link_html; - + } /** * Get checkboxes for multiple row data operations - * + * * @param array $vertical_display the information to display * @param string $dir _left / _right - * + * * @return $checkBoxes_html html content - * + * * @see PMA_getVerticalTable() */ function PMA_getCheckBoxesForMultipleRowOperations($vertical_display, $dir) { - + $checkBoxes_html = ''; $cell_displayed = 0; - + foreach ($vertical_display['row_delete'] as $val) { if (($cell_displayed != 0) @@ -3257,9 +3257,9 @@ function PMA_getCheckBoxesForMultipleRowOperations($vertical_display, $dir) { $checkBoxes_html .= str_replace('[%_PMA_CHECKBOX_DIR_%]', $dir, $val); $cell_displayed++; } // end while - + return $checkBoxes_html; - + } @@ -3276,7 +3276,7 @@ function PMA_getCheckBoxesForMultipleRowOperations($vertical_display, $dir) { */ function PMA_setConfigParamsForDisplayTable() { - + $sql_md5 = md5($GLOBALS['sql_query']); $_SESSION['tmp_user_values']['query'][$sql_md5]['sql'] = $GLOBALS['sql_query']; @@ -3285,7 +3285,7 @@ function PMA_setConfigParamsForDisplayTable() $_REQUEST['disp_direction'], array('horizontal', 'vertical', 'horizontalflipped') ); - + if ($valid_disp_dir) { $_SESSION['tmp_user_values']['query'][$sql_md5]['disp_direction'] = $_REQUEST['disp_direction']; @@ -3444,7 +3444,7 @@ function PMA_setConfigParamsForDisplayTable() = $_SESSION['tmp_user_values']['query'][$sql_md5]['repeat_cells']; $_SESSION['tmp_user_values']['disp_direction'] = $_SESSION['tmp_user_values']['query'][$sql_md5]['disp_direction']; - + } @@ -3456,7 +3456,7 @@ function PMA_setConfigParamsForDisplayTable() * which results have to be displayed * @param array &$the_disp_mode the display mode * @param array $analyzed_sql the analyzed query - * + * * @return sting Generated HTML content for resulted table * * @global string $db the database name @@ -3487,13 +3487,13 @@ function PMA_setConfigParamsForDisplayTable() */ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) { - + global $db, $table, $goto; global $sql_query, $num_rows, $unlim_num_rows, $fields_meta, $fields_cnt; global $vertical_display, $highlight_columns; global $cfgRelation; global $showtable; - + $table_html = ''; // why was this called here? (already called from sql.php) @@ -3537,26 +3537,26 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) // 1.3 Find the sort expression // we need $sort_expression and $sort_expression_nodirection - // even if there are many table references + // even if there are many table references list($sort_expression, $sort_expression_nodirection, $sort_direction) = PMA_getSortParams($analyzed_sql[0]['order_by_clause']); - - + + // 1.4 Prepares display of first and last value of the sorted column $sorted_column_message = PMA_getSortedColumnMessage( $dt_result, $fields_meta, $num_rows, $sort_expression_nodirection, $table ); - + // 2. ----- Prepare to display the top of the page ----- // 2.1 Prepares a messages with position informations - if (($is_display['nav_bar'] == '1') && isset($pos_next)) { + if (($is_display['nav_bar'] == '1') && isset($pos_next)) { $message = PMA_setMessageInformation( - $db, $table, $sorted_column_message, + $db, $table, $sorted_column_message, $analyzed_sql[0]['limit_clause'], $unlim_num_rows, $total, $pos_next, $pre_count, $after_count ); @@ -3564,7 +3564,7 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) $table_html .= PMA_getMessage($message, $sql_query, 'success'); } elseif (! isset($GLOBALS['printview']) || ($GLOBALS['printview'] != '1')) { - + $table_html .= PMA_getMessage( __('Your SQL query has been executed successfully'), $sql_query, 'success' @@ -3573,7 +3573,7 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) // 2.3 Prepare the navigation bars if (! strlen($table)) { - + if (isset($analyzed_sql[0]['query_type']) && ($analyzed_sql[0]['query_type'] == 'SELECT') ) { @@ -3584,16 +3584,16 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) } else { $table = ''; } - + } if (($is_display['nav_bar'] == '1') && empty($analyzed_sql[0]['limit_clause'])) { - + $table_html .= PMA_getTableNavigation( $pos_next, $pos_prev, $sql_query, 'top_direction_dropdown' ) . "\n"; - + } elseif (! isset($GLOBALS['printview']) || ($GLOBALS['printview'] != '1')) { $table_html .= "\n" . '

' . "\n"; } @@ -3609,20 +3609,20 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) if (isset($analyzed_sql[0]['table_ref']) && is_array($analyzed_sql[0]['table_ref']) ) { - + foreach ($analyzed_sql[0]['table_ref'] as $table_ref_position => $table_ref) { $target[] = $analyzed_sql[0]['table_ref'][$table_ref_position]['table_true_name']; } - + } - + $tabs = '(\'' . join('\',\'', $target) . '\')'; if (! strlen($table)) { $exist_rel = false; } else { - + // To be able to later display a link to the related table, // we verify both types of relations: either those that are // native foreign keys or those defined in the phpMyAdmin @@ -3630,15 +3630,15 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) // to use the "column to display" notion (for example show // the name related to a numeric id). $exist_rel = PMA_getForeigners($db, $table, '', 'both'); - + if ($exist_rel) { - + foreach ($exist_rel as $master_field => $rel) { - + $display_field = PMA_getDisplayField( $rel['foreign_db'], $rel['foreign_table'] ); - + $map[$master_field] = array( $rel['foreign_table'], $rel['foreign_field'], @@ -3656,21 +3656,21 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) $sort_expression, $sort_expression_nodirection, $sort_direction ) . '' . "\n"; - - $url_query = ''; + + $url_query = ''; $table_html .= PMA_getTableBody( $dt_result, $is_display, $map, $analyzed_sql - ); - + ); + // vertical output case if ($_SESSION['tmp_user_values']['disp_direction'] == 'vertical') { $table_html .= PMA_getVerticalTable(); } // end if - + unset($vertical_display); $table_html .= '' . "\n" . ''; - + // 4. ----- Prepares the link for multi-fields edit and delete if ($is_display['del_lnk'] == 'dr' && $is_display['del_lnk'] != 'kp') { @@ -3685,12 +3685,12 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) // 5. ----- Get the navigation bar at the bottom if required ----- if ($is_display['nav_bar'] == '1' && empty($analyzed_sql[0]['limit_clause'])) { - + $table_html .= '
' . "\n"; $table_html .= PMA_getTableNavigation( $pos_next, $pos_prev, $sql_query, 'bottom_direction_dropdown' ); - + } elseif (! isset($GLOBALS['printview']) || $GLOBALS['printview'] != '1') { $table_html .= "\n" . '

' . "\n"; } @@ -3699,22 +3699,22 @@ function PMA_getTable(&$dt_result, &$the_disp_mode, $analyzed_sql) if (! isset($GLOBALS['printview']) || $GLOBALS['printview'] != '1') { $table_html .= PMA_getResultsOperations($the_disp_mode, $analyzed_sql); } - + return $table_html; - + } // end of the 'PMA_getTable()' function /** * Get offsets for next page and previous page - * + * * @return array array with two elements - $pos_next, $pos_prev - * + * * @see PMA_getTable() */ function PMA_getOffsets() { - + if ($_SESSION['tmp_user_values']['max_rows'] == 'all') { $pos_next = 0; $pos_prev = 0; @@ -3730,27 +3730,27 @@ function PMA_getOffsets() $pos_prev = 0; } } - + return array($pos_next, $pos_prev); - + } /** * Get sort parameters - * - * @param string $order_by_clause - * + * + * @param string $order_by_clause + * * @return array 3 element array: $sort_expression, * $sort_expression_nodirection, $sort_direction - * + * * @see PMA_getTable() */ function PMA_getSortParams($order_by_clause) { - + if (! empty($order_by_clause)) { - + $sort_expression = trim( str_replace(' ', ' ', $order_by_clause) ); @@ -3758,26 +3758,26 @@ function PMA_getSortParams($order_by_clause) * Get rid of ASC|DESC */ preg_match('@(.*)([[:space:]]*(ASC|DESC))@si', $sort_expression, $matches); - + $sort_expression_nodirection = isset($matches[1]) ? trim($matches[1]) : $sort_expression; - + $sort_direction = isset($matches[2]) ? trim($matches[2]) : ''; unset($matches); - + } else { $sort_expression = $sort_expression_nodirection = $sort_direction = ''; } - + return array($sort_expression, $sort_expression_nodirection, $sort_direction); - + } /** * Prepare sorted column message - * + * * @param integer &$dt_result the link id associated to the query * which results have to be displayed * @param array $fields_meta the list of fields properties @@ -3785,18 +3785,18 @@ function PMA_getSortParams($order_by_clause) * by the SQL query * @param string $sort_expression_nodirection sort expression without direction * @param string $table the table name - * + * * @return string html content * null if not found sorted column - * + * * @see PMA_getTable() */ function PMA_getSortedColumnMessage(&$dt_result, $fields_meta, $num_rows, $sort_expression_nodirection, $table ) { - + if (! empty($sort_expression_nodirection)) { - + if (strpos($sort_expression_nodirection, '.') === false) { $sort_table = $table; $sort_column = $sort_expression_nodirection; @@ -3804,88 +3804,88 @@ function PMA_getSortedColumnMessage(&$dt_result, $fields_meta, list($sort_table, $sort_column) = explode('.', $sort_expression_nodirection); } - + $sort_table = PMA_unQuote($sort_table); $sort_column = PMA_unQuote($sort_column); - + // find the sorted column index in row result // (this might be a multi-table query) $sorted_column_index = false; - + foreach ($fields_meta as $key => $meta) { if (($meta->table == $sort_table) && ($meta->name == $sort_column)) { $sorted_column_index = $key; break; } } - + if ($sorted_column_index !== false) { - + // fetch first row of the result set $row = PMA_DBI_fetch_row($dt_result); - + // initializing default arguments $default_function = 'PMA_mimeDefaultFunction'; $transform_function = $default_function; $transform_options = array(); - + // check for non printable sorted row data $meta = $fields_meta[$sorted_column_index]; - + if (stristr($meta->type, 'BLOB') || ($meta->type == 'geometry')) { - + $column_for_first_row = PMA_handleNonPrintableContents( $meta->type, $row[$sorted_column_index], $transform_function, $transform_options, $default_function, $meta, null ); - + } else { $column_for_first_row = $row[$sorted_column_index]; } - + $column_for_first_row = strtoupper( substr($column_for_first_row, 0, $GLOBALS['cfg']['LimitChars']) ); - + // fetch last row of the result set PMA_DBI_data_seek($dt_result, $num_rows - 1); $row = PMA_DBI_fetch_row($dt_result); - + // check for non printable sorted row data $meta = $fields_meta[$sorted_column_index]; if (stristr($meta->type, 'BLOB') || ($meta->type == 'geometry')) { - + $column_for_last_row = PMA_handleNonPrintableContents( $meta->type, $row[$sorted_column_index], $transform_function, $transform_options, $default_function, $meta, null ); - + } else { $column_for_last_row = $row[$sorted_column_index]; } - + $column_for_last_row = strtoupper( substr($column_for_last_row, 0, $GLOBALS['cfg']['LimitChars']) ); - + // reset to first row for the loop in PMA_getTableBody() PMA_DBI_data_seek($dt_result, 0); - + // we could also use here $sort_expression_nodirection return ' [' . htmlspecialchars($sort_column) . ': ' . htmlspecialchars($column_for_first_row) . ' - ' . htmlspecialchars($column_for_last_row) . ']'; } } - + return null; - + } /** * Set the content need to be show in message - * + * * @param string $db the database name * @param string $table the table name * @param string $sorted_column_message the message for sorted column @@ -3894,21 +3894,21 @@ function PMA_getSortedColumnMessage(&$dt_result, $fields_meta, * the SQL query without any appended * "LIMIT" clause programmatically * @param integer $total the total number of rows returned by - * the SQL query without any + * the SQL query without any * programmatically appended LIMIT clause * @param integer $pos_next the offset for next page * @param string $pre_count the string renders before row count * @param string $after_count the string renders after row count - * + * * @return PMA_Message $message an object of PMA_Message - * + * * @see PMA_getTable() */ function PMA_setMessageInformation( $db, $table, $sorted_column_message, $limit_clause, $unlim_num_rows, $total, $pos_next, $pre_count, $after_count ) { - + if (isset($unlim_num_rows) && ($unlim_num_rows != $total)) { $selectstring = ', ' . $unlim_num_rows . ' ' . __('in query'); } else { @@ -3988,15 +3988,15 @@ function PMA_setMessageInformation( if (! is_null($sorted_column_message)) { $message->addMessage($sorted_column_message, ''); } - + return $message; - + } /** * Prepare multi field edit/delete links - * + * * @param integer &$dt_result the link id associated to the query * which results have to be displayed * @param integer $fields_cnt the total number of fields returned by @@ -4010,16 +4010,16 @@ function PMA_setMessageInformation( * @param string $sql_query the current SQL query * @param string $goto the URL to go back in case of errors * @param string $del_link the display element - 'del_link' - * + * * @return string $links_html html content - * + * * @see PMA_getTable() */ function PMA_getMultiRowOperationLinks( &$dt_result, $fields_cnt, $fields_meta, $num_rows, $analyzed_sql, $db, $table, $sql_query, $goto, $del_link ) { - + $links_html = ''; $delete_text = ($del_link == 'dr') ? __('Delete') : __('Kill'); @@ -4114,9 +4114,9 @@ function PMA_getMultiRowOperationLinks( .' value="' . $clause_is_unique . '" />' . "\n"; $links_html .= '' . "\n"; - + return $links_html; - + } @@ -4144,7 +4144,7 @@ function PMA_mimeDefaultFunction($buffer) * @param array $analyzed_sql the analyzed query * * @return string html content - * + * * @global string $db the database name * @global string $table the table name * @global string $sql_query the current SQL query @@ -4162,7 +4162,7 @@ function PMA_mimeDefaultFunction($buffer) */ function PMA_getResultsOperations($the_disp_mode, $analyzed_sql) { - + global $db, $table, $sql_query, $unlim_num_rows, $fields_meta; $results_operations_html = ''; @@ -4194,9 +4194,9 @@ function PMA_getResultsOperations($the_disp_mode, $analyzed_sql) . "\n"; if ($_SESSION['tmp_user_values']['display_text']) { - + $_url_params['display_text'] = 'F'; - + $results_operations_html .= PMA_linkOrButton( 'sql.php' . PMA_generate_common_url($_url_params), PMA_getIcon( @@ -4222,18 +4222,18 @@ function PMA_getResultsOperations($the_disp_mode, $analyzed_sql) && ! isset($printview) && ! isset($analyzed_sql[0]['queryflags']['procedure']) ) { - + if (isset($analyzed_sql[0]['table_ref'][0]['table_true_name']) && ! isset($analyzed_sql[0]['table_ref'][1]['table_true_name']) ) { $_url_params['single_table'] = 'true'; } - + if (!$header_shown) { $results_operations_html .= $header; $header_shown = true; } - + $_url_params['unlim_num_rows'] = $unlim_num_rows; /** @@ -4276,7 +4276,7 @@ function PMA_getResultsOperations($the_disp_mode, $analyzed_sql) break; } } - + if ($geometry_found) { $results_operations_html .= PMA_linkOrButton( 'tbl_gis_visualization.php' . PMA_generate_common_url($_url_params), @@ -4299,11 +4299,11 @@ function PMA_getResultsOperations($the_disp_mode, $analyzed_sql) $results_operations_html .= $header; $header_shown = true; } - + if (!PMA_DRIZZLE && !isset($analyzed_sql[0]['queryflags']['procedure'])) { - + $ajax_class = $GLOBALS['cfg']['AjaxEnable'] ? ' ajax' : ''; - + $results_operations_html .= '' . PMA_linkOrButton( 'view_create.php' . $url_query, @@ -4312,13 +4312,13 @@ function PMA_getResultsOperations($the_disp_mode, $analyzed_sql) ) . '' . "\n"; } - + if ($header_shown) { $results_operations_html .= '
'; } - + return $results_operations_html; - + } @@ -4339,34 +4339,34 @@ function PMA_getResultsOperations($the_disp_mode, $analyzed_sql) function PMA_handleNonPrintableContents($category, $content, $transform_function, $transform_options, $default_function, $meta, $url_params = array() ) { - + $result = '[' . $category; - + if (is_null($content)) { - + $result .= ' - NULL'; $size = 0; - + } elseif (isset($content)) { - + $size = strlen($content); $display_size = PMA_formatByteDown($size, 3, 1); $result .= ' - '. $display_size[0] . ' ' . $display_size[1]; - + } - + $result .= ']'; if (strpos($transform_function, 'octetstream')) { $result = $content; } - + if ($size > 0) { - + if ($default_function != $transform_function) { $result = $transform_function($result, $transform_options, $meta); } else { - + $result = $default_function($result, array(), $meta); if (stristr($meta->type, 'BLOB') && $_SESSION['tmp_user_values']['display_blob'] @@ -4374,7 +4374,7 @@ function PMA_handleNonPrintableContents($category, $content, $transform_function // in this case, restart from the original $content $result = htmlspecialchars(PMA_replaceBinaryContents($content)); } - + /* Create link to download */ if (count($url_params) > 0) { $result = ' $select_expr ) { - + $alias = $analyzed_sql[0]['select_expr'][$select_expr_position]['alias']; - + if (isset($alias) && strlen($alias)) { $true_column = $analyzed_sql[0]['select_expr'][$select_expr_position]['column']; - + if ($alias == $meta->name) { // this change in the parameter does not matter // outside of the function $meta->name = $true_column; } // end if - + } // end if } // end foreach } // end if if (isset($map[$meta->name])) { - + // Field to display from the foreign table? if (isset($map[$meta->name][2]) && strlen($map[$meta->name][2])) { - + $dispsql = 'SELECT ' . PMA_backquote($map[$meta->name][2]) . ' FROM ' . PMA_backquote($map[$meta->name][3]) . '.' . PMA_backquote($map[$meta->name][0]) . ' WHERE ' . PMA_backquote($map[$meta->name][1]) . $where_comparison; - + $dispresult = PMA_DBI_try_query($dispsql, null, PMA_DBI_QUERY_STORE); - + if ($dispresult && PMA_DBI_num_rows($dispresult) > 0) { list($dispval) = PMA_DBI_fetch_row($dispresult, 0); } else { $dispval = __('Link not found'); } - + @PMA_DBI_free_result($dispresult); - + } else { $dispval = ''; } // end if... else... if (isset($GLOBALS['printview']) && $GLOBALS['printview'] == '1') { - + $result .= ($transform_function != $default_function ? $transform_function($data, $transform_options, $meta) : $transform_function($data, array(), $meta)) . ' [->' . $dispval . ']'; - + } else { if ($_SESSION['tmp_user_values']['relational_display'] == 'K') { - + // user chose "relational key" in the display options, so // the title contains the display field $title = (! empty($dispval))? ' title="' . htmlspecialchars($dispval) . '"' : ''; - + } else { $title = ' title="' . htmlspecialchars($data) . '"'; } @@ -4499,7 +4499,7 @@ function PMA_getRowData($class, $condition_field, $analyzed_sql, $meta, $map, . ' WHERE ' . PMA_backquote($map[$meta->name][1]) . $where_comparison, ); - + $result .= ''; @@ -4508,7 +4508,7 @@ function PMA_getRowData($class, $condition_field, $analyzed_sql, $meta, $map, // not on the display field $result .= $transform_function($data, $transform_options, $meta); } else { - + if ($_SESSION['tmp_user_values']['relational_display'] == 'D') { // user chose "relational display field" in the // display options, so show display field in the cell @@ -4517,11 +4517,11 @@ function PMA_getRowData($class, $condition_field, $analyzed_sql, $meta, $map, // otherwise display data in the cell $result .= $transform_function($data, array(), $meta); } - + } $result .= ''; } - + } else { $result .= ($transform_function != $default_function) ? $transform_function($data, $transform_options, $meta) @@ -4553,7 +4553,7 @@ function PMA_getRowData($class, $condition_field, $analyzed_sql, $meta, $map, $result .= '' . "\n"; return $result; - + } @@ -4575,16 +4575,16 @@ function PMA_getRowData($class, $condition_field, $analyzed_sql, $meta, $map, function PMA_getCheckboxForMultiRowSubmissions($del_url, $is_display, $row_no, $where_clause_html, $condition_array, $del_query, $id_suffix, $class ) { - + $ret = ''; - + if (! empty($del_url) && $is_display['del_lnk'] != 'kp') { - - $ret .= '' . '' - . ' '; + . ' '; } - + return $ret; - + } @@ -4618,10 +4618,10 @@ function PMA_getCheckboxForMultiRowSubmissions($del_url, $is_display, $row_no, function PMA_getEditLink($edit_url, $class, $edit_str, $where_clause, $where_clause_html ) { - + $ret = ''; if (! empty($edit_url)) { - + $ret .= '' . PMA_linkOrButton($edit_url, $edit_str, array(), false); /* @@ -4634,9 +4634,9 @@ function PMA_getEditLink($edit_url, $class, $edit_str, $where_clause, } $ret .= ''; } - + return $ret; - + } @@ -4654,18 +4654,18 @@ function PMA_getEditLink($edit_url, $class, $edit_str, $where_clause, function PMA_getCopyLink($copy_url, $copy_str, $where_clause, $where_clause_html, $class ) { - + $ret = ''; if (! empty($copy_url)) { - + $ret .= '' . PMA_linkOrButton($copy_url, $copy_str, array(), false); - + /* * Where clause for selecting this row uniquely is provided as * a hidden input. Used by jQuery scripts for handling grid editing @@ -4676,9 +4676,9 @@ function PMA_getCopyLink($copy_url, $copy_str, $where_clause, } $ret .= ''; } - + return $ret; - + } @@ -4694,22 +4694,22 @@ function PMA_getCopyLink($copy_url, $copy_str, $where_clause, */ function PMA_getDeleteLink($del_url, $del_str, $js_conf, $class) { - + $ret = ''; if (! empty($del_url)) { - + $ret .= '' . PMA_linkOrButton($del_url, $del_str, $js_conf, false) . ''; } - + return $ret; - + } @@ -4740,11 +4740,11 @@ function PMA_getCheckboxAndLinks($position, $del_url, $is_display, $row_no, $where_clause, $where_clause_html, $condition_array, $del_query, $id_suffix, $edit_url, $copy_url, $class, $edit_str, $copy_str, $del_str, $js_conf ) { - + $ret = ''; if ($position == 'left') { - + $ret .= PMA_getCheckboxForMultiRowSubmissions( $del_url, $is_display, $row_no, $where_clause_html, $condition_array, $del_query, $id_suffix = '_left', '', '', '' @@ -4761,7 +4761,7 @@ function PMA_getCheckboxAndLinks($position, $del_url, $is_display, $row_no, $ret .= PMA_getDeleteLink($del_url, $del_str, $js_conf, '', ''); } elseif ($position == 'right') { - + $ret .= PMA_getDeleteLink($del_url, $del_str, $js_conf, '', ''); $ret .= PMA_getCopyLink( @@ -4776,16 +4776,16 @@ function PMA_getCheckboxAndLinks($position, $del_url, $is_display, $row_no, $del_url, $is_display, $row_no, $where_clause_html, $condition_array, $del_query, $id_suffix = '_right', '', '', '' ); - + } else { // $position == 'none' - + $ret .= PMA_getCheckboxForMultiRowSubmissions( $del_url, $is_display, $row_no, $where_clause_html, $condition_array, $del_query, $id_suffix = '_left', '', '', '' ); } - + return $ret; - + } ?>