diff --git a/adminer/select.inc.php b/adminer/select.inc.php
index 422014ba..b3697724 100644
--- a/adminer/select.inc.php
+++ b/adminer/select.inc.php
@@ -403,7 +403,7 @@ if (!$columns) {
$text = ereg('text|lob', $field["type"]);
echo (($_GET["modify"] && $editable) || $value !== null
? "
" . ($text ? "" : "")
- : " | " . $adminer->selectVal($val, $link, $field)
+ : " | " . $adminer->selectVal($val, $link, $field)
);
}
}
diff --git a/adminer/static/functions.js b/adminer/static/functions.js
index a1f563d0..7bb56851 100644
--- a/adminer/static/functions.js
+++ b/adminer/static/functions.js
@@ -412,11 +412,16 @@ function ajaxSetHtml(url) {
* @param HTMLElement
* @param MouseEvent
* @param number display textarea instead of input, 2 - load long text
+* @param string warning to display
*/
-function selectClick(td, event, text) {
- if (!event.ctrlKey || /input|textarea/i.test(td.firstChild.tagName)) {
+function selectClick(td, event, text, warning) {
+ var target = event.target || event.srcElement;
+ if (!event.ctrlKey || /input|textarea/i.test(td.firstChild.tagName) || /^a$/i.test(target.tagName)) {
return;
}
+ if (warning) {
+ return alert(warning);
+ }
var original = td.innerHTML;
text = text || /\n/.test(original);
var input = document.createElement(text ? 'textarea' : 'input');
|