", "<=", ">=", "!=", "LIKE", "REGEXP", "IN", "IS NULL", "NOT LIKE", "NOT REGEXP", "NOT IN", "IS NOT NULL");
/** Name in title and navigation
* @return string
*/
function name() {
return "Adminer";
}
/** Connection parameters
* @return array ($server, $username, $password)
*/
function credentials() {
return array($_GET["server"], $_SESSION["usernames"][$_GET["server"]], $_SESSION["passwords"][$_GET["server"]]);
}
/** Identifier of selected database
* @return string
*/
function database() {
// should be used everywhere instead of $_GET["db"]
return $_GET["db"];
}
/** Print login form
* @param string
* @return null
*/
function loginForm($username) {
?>
">
' . h($field["field"]) . '';
}
/** Links after select heading
* @param array result of SHOW TABLE STATUS
* @return string
*/
function selectLinks($tableStatus) {
return '' . lang('Table structure') . '';
}
/** Find backward keys for table
* @param string
* @return array $return[$target_table][$key_name][$target_column] = $source_column;
*/
function backwardKeys($table) {
return array();
}
/** Query printed in select before execution
* @param string query to be executed
* @return string
*/
function selectQuery($query) {
// it would be nice if $query can be passed by reference and printed value would be returned but call_user() doesn't allow reference parameters
return "
" . h($query) . "" . lang('Edit') . "\n";
}
/** Description of a row in a table
* @param string
* @return string SQL expression, empty string for no description
*/
function rowDescription($table) {
return "";
}
/** Get descriptions of selected data
* @param array all data to print
* @param array
* @return array
*/
function rowDescriptions($rows, $foreignKeys) {
return $rows;
}
/** Value printed in select table
* @param string HTML-escaped value to print
* @param string link to foreign key
* @param array single field returned from fields()
* @return string
*/
function selectVal($val, $link, $field) {
$return = ($field["type"] == "char" ? "$val" : $val);
if (ereg('blob|binary', $field["type"]) && !is_utf8($val)) {
$return = lang('%d byte(s)', strlen($val));
}
return ($link ? "$return" : $return);
}
/** Value conversion used in select and edit
* @param string
* @param array single field returned from fields()
* @return string
*/
function editVal($val, $field) {
return $val;
}
/** Print columns box in select
* @param array result of selectColumnsProcess()
* @param array selectable columns
* @return null
*/
function selectColumnsPrint($select, $columns) {
echo '
\n";
}
/** Print search box in select
* @param array result of selectSearchProcess()
* @param array selectable columns
* @param array
* @return null
*/
function selectSearchPrint($where, $columns, $indexes) {
echo '\n";
}
/** Print order box in select
* @param array result of selectOrderProcess()
* @param array selectable columns
* @param array
* @return null
*/
function selectOrderPrint($order, $columns, $indexes) {
echo '\n";
}
/** Print limit box in select
* @param string result of selectLimitProcess()
* @return null
*/
function selectLimitPrint($limit) {
echo "