Bind event externally.
This commit is contained in:
@@ -1718,5 +1718,10 @@ $(document).ready(function(){
|
||||
$("#btnDiscard").live("click",function(){
|
||||
$(".sql").html("<span class=\"syntax\">"+$oldText+"</span>");
|
||||
});
|
||||
|
||||
jQuery('.sqlbutton').click(function(evt){
|
||||
insertQuery(evt.target.id);
|
||||
return false;
|
||||
});
|
||||
});
|
||||
|
||||
|
@@ -298,11 +298,11 @@ function PMA_sqlQueryFormInsert($query = '', $is_querywindow = false, $delimiter
|
||||
.$auto_sel . $locking . '>' . htmlspecialchars($query) . '</textarea>' . "\n";
|
||||
// Add buttons to generate query easily for select all,single select,insert,update and delete
|
||||
if(count($fields_list)) {
|
||||
echo '<input type="button" value="' . __('SELECT *') . '" id="selectall" onclick="insertQuery(this.id)" />';
|
||||
echo '<input type="button" value="' . __('SELECT') . '" id="select" onclick="insertQuery(this.id)" />';
|
||||
echo '<input type="button" value="' . __('INSERT') . '" id="insert" onclick="insertQuery(this.id)" />';
|
||||
echo '<input type="button" value="' . __('UPDATE') . '" id="update" onclick="insertQuery(this.id)" />';
|
||||
echo '<input type="button" value="' . __('DELETE') . '" id="delete" onclick="insertQuery(this.id)" />';
|
||||
echo '<input type="button" value="' . __('SELECT *') . '" id="selectall" class="sqlbutton" />';
|
||||
echo '<input type="button" value="' . __('SELECT') . '" id="select" class="sqlbutton" />';
|
||||
echo '<input type="button" value="' . __('INSERT') . '" id="insert" class="sqlbutton" />';
|
||||
echo '<input type="button" value="' . __('UPDATE') . '" id="update" class="sqlbutton" />';
|
||||
echo '<input type="button" value="' . __('DELETE') . '" id="delete" class="sqlbutton" />';
|
||||
}
|
||||
echo '</div>' . "\n";
|
||||
|
||||
|
Reference in New Issue
Block a user