diff --git a/libraries/tbl_select.lib.php b/libraries/tbl_select.lib.php
index 8f234590d3..b18ceb5844 100644
--- a/libraries/tbl_select.lib.php
+++ b/libraries/tbl_select.lib.php
@@ -121,6 +121,144 @@ function PMA_tbl_getSubTabs()
return $subtabs;
}
+/**
+ * Provides html elements for search criteria inputbox
+ * in case the column's type is geometrical
+ *
+ * @param int $column_index Column's index
+ * @param bool $in_fbs Whether we are in 'function based search'
+ *
+ * @return HTML elements.
+ */
+function PMA_tblSearchGetGeometricalInputBox($column_index, $in_fbs)
+{
+ $html_output = '';
+
+ if ($in_fbs) {
+ $edit_url = 'gis_data_editor.php?' . PMA_generate_common_url();
+ $edit_str = PMA_getIcon('b_edit.png', __('Edit/Insert'));
+ $html_output .= '';
+ $html_output .= PMA_linkOrButton(
+ $edit_url, $edit_str, array(), false, false, '_blank'
+ );
+ $html_output .= '';
+ }
+ return $html_output;
+}
+
+/**
+ * Provides html elements for search criteria inputbox
+ * in case the column is a Foreign Key
+ *
+ * @param array $foreignData Foreign keys data
+ * @param string $field Column name
+ * @param int $column_index Column index
+ * @param string $db Selected database
+ * @param string $table Selected table
+ * @param array $titles Selected title
+ * @param int $foreignMaxLimit Max limit of displaying foreign elements
+ * @param array $criteriaValues Array of search criteria inputs
+ * @param string $field_id Column's inputbox's id
+ * @param bool $in_zoom_search_edit Whether we are in zoom search edit
+ *
+ * @return HTML elements.
+ */
+function PMA_tblSearchGetForeignKeyInputBox($foreignData, $field, $column_index,
+ $db, $table, $titles, $foreignMaxLimit, $criteriaValues,
+ $field_id, $in_zoom_search_edit = false
+) {
+ $html_output = '';
+ if (is_array($foreignData['disp_row'])) {
+ $html_output .= '';
+
+ } elseif ($foreignData['foreign_link'] == true) {
+ $html_output .= '';
+
+ $html_output .= <<';
+ }
+ return $html_output;
+}
+
+/**
+ * Provides html elements for search criteria inputbox
+ * in case the column is of ENUM or SET type
+ *
+ * @param int $column_index Column index
+ * @param array $criteriaValues Array of search criteria inputs
+ * @param string $field_type Column type
+ * @param string $field_id Column's inputbox's id
+ * @param bool $in_zoom_search_edit Whether we are in zoom search edit
+ *
+ * @return HTML elements.
+ */
+function PMA_tblSearchGetEnumSetInputBox($column_index, $criteriaValues, $field_type,
+ $field_id, $in_zoom_search_edit = false
+) {
+ $html_output = '';
+ $value = explode(
+ ', ',
+ str_replace("'", '', substr($field_type, 5, -1))
+ );
+ $cnt_value = count($value);
+
+ /*
+ * Enum in edit mode --> dropdown
+ * Enum in search mode --> multiselect
+ * Set in edit mode --> multiselect
+ * Set in search mode --> input (skipped here, so the 'else'
+ * section would handle it)
+ */
+ if ((strncasecmp($field_type, 'enum', 4) && ! $in_zoom_search_edit)
+ || (strncasecmp($field_type, 'set', 3) && $in_zoom_search_edit)
+ ) {
+ $html_output .= '