<input type="submit" value="<?php echo lang('Save'); ?>">
<?php } ?>
-<?php if ($TABLE != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(); ?><?php } ?>
+<?php if ($TABLE != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(lang('Drop') . " $TABLE"); ?><?php } ?>
<?php
if (support("partitioning")) {
$partition_table = preg_match('~RANGE|LIST~', $row["partition_by"]);
<input type="submit" value="<?php echo lang('Save'); ?>">
<?php
if (DB != "") {
- echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm() . "\n";
+ echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm(lang('Drop') . " " . DB) . "\n";
} elseif (!$_POST["add_x"] && $_GET["db"] == "") {
echo "<input type='image' class='icon' name='add' src='../adminer/static/plus.gif' alt='+' title='" . lang('Add next') . "'>\n";
}
<p><?php textarea("EVENT_DEFINITION", $row["EVENT_DEFINITION"]); ?>
<p>
<input type="submit" value="<?php echo lang('Save'); ?>">
-<?php if ($EVENT != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(); ?><?php } ?>
+<?php if ($EVENT != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(lang('Drop') . " $EVENT"); ?><?php } ?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
</form>
<input type="submit" value="<?php echo lang('Save'); ?>">
<noscript><p><input type="submit" name="add" value="<?php echo lang('Add column'); ?>"></noscript>
<?php } ?>
-<?php if ($name != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(); ?><?php } ?>
+<?php if ($name != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(lang('Drop') . " $name"); ?><?php } ?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
</form>
/** Get onclick confirmation
* @param string
+* @param string
* @return string
*/
-function confirm($selector = "qsl('input')") {
- return script("$selector.onclick = function () { return confirm('" . lang('Are you sure?') . "'); };", "");
+function confirm($message = "", $selector = "qsl('input')") {
+ return script("$selector.onclick = function () { return confirm('" . ($message ? js_escape($message) . ". " : "") . lang('Are you sure?') . "'); };", "");
}
/** Print header for hidden fieldset (close by </div></fieldset>)
<p><?php textarea("definition", $row["definition"]); ?>
<p>
<input type="submit" value="<?php echo lang('Save'); ?>">
-<?php if ($PROCEDURE != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(); ?><?php } ?>
+<?php if ($PROCEDURE != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(lang('Drop') . " $PROCEDURE"); ?><?php } ?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
</form>
<input type="submit" value="<?php echo lang('Save'); ?>">
<?php
if ($_GET["ns"] != "") {
- echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm() . "\n";
+ echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm(lang('Drop') . " $_GET[ns]") . "\n";
}
?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
<input type="submit" value="<?php echo lang('Save'); ?>">
<?php
if ($SEQUENCE != "") {
- echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm() . "\n";
+ echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm(lang('Drop') . " $SEQUENCE") . "\n";
}
?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
<p><?php textarea("Statement", $row["Statement"]); ?>
<p>
<input type="submit" value="<?php echo lang('Save'); ?>">
-<?php if ($name != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(); ?><?php } ?>
+<?php if ($name != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(lang('Drop') . " $name"); ?><?php } ?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
</form>
<p>
<?php
if ($TYPE != "") {
- echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm() . "\n";
+ echo "<input type='submit' name='drop' value='" . lang('Drop') . "'>" . confirm(lang('Drop') . " $TYPE") . "\n";
} else {
echo "<input name='name' value='" . h($row['name']) . "' autocapitalize='off'>\n";
textarea("as", $row["as"]);
?>
<p>
<input type="submit" value="<?php echo lang('Save'); ?>">
-<?php if (isset($_GET["host"])) { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(); ?><?php } ?>
+<?php if (isset($_GET["host"])) { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(lang('Drop') . " $USER@$_GET[host]"); ?><?php } ?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
</form>
<p><?php textarea("select", $row["select"]); ?>
<p>
<input type="submit" value="<?php echo lang('Save'); ?>">
-<?php if ($_GET["view"] != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(); ?><?php } ?>
+<?php if ($TABLE != "") { ?><input type="submit" name="drop" value="<?php echo lang('Drop'); ?>"><?php echo confirm(lang('Drop') . " $TABLE"); ?><?php } ?>
<input type="hidden" name="token" value="<?php echo $token; ?>">
</form>
Adminer 4.5.0-dev:
+Display name of the object in confirmation when dropping it
Display newlines in column comments (bug #573)
Support current_timestamp() as default of time fields (bug #572)
Hide window.opener from pages opened in a new window (bug #561)