Skip to content

Commit

Permalink
Merge branch 'master' into useNamespaces_master
Browse files Browse the repository at this point in the history
  • Loading branch information
Tithugues committed Sep 10, 2015
2 parents 42169e0 + bf311ef commit f08bc1a
Show file tree
Hide file tree
Showing 19 changed files with 88 additions and 71 deletions.
14 changes: 7 additions & 7 deletions js/db_operations.js
Expand Up @@ -53,7 +53,7 @@ AJAX.registerOnload('db_operations.js', function () {

$form.PMA_confirm(question, $form.attr('action'), function (url) {
PMA_ajaxShowMessage(PMA_messages.strRenamingDatabases, false);
$.get(url, $("#rename_db_form").serialize() + '&is_js_confirmed=1', function (data) {
$.post(url, $("#rename_db_form").serialize() + '&is_js_confirmed=1', function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxShowMessage(data.message);
PMA_commonParams.set('db', data.newname);
Expand All @@ -73,7 +73,7 @@ AJAX.registerOnload('db_operations.js', function () {
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get()
}); // end $.post()
});
}); // end Rename Database

Expand All @@ -85,7 +85,7 @@ AJAX.registerOnload('db_operations.js', function () {
PMA_ajaxShowMessage(PMA_messages.strCopyingDatabase, false);
var $form = $(this);
PMA_prepareForAjaxRequest($form);
$.get($form.attr('action'), $form.serialize(), function (data) {
$.post($form.attr('action'), $form.serialize(), function (data) {
// use messages that stay on screen
$('div.success, div.error').fadeOut();
if (typeof data !== 'undefined' && data.success === true) {
Expand All @@ -102,7 +102,7 @@ AJAX.registerOnload('db_operations.js', function () {
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get
}); // end $.post()
}); // end copy database

/**
Expand All @@ -113,13 +113,13 @@ AJAX.registerOnload('db_operations.js', function () {
var $form = $(this);
PMA_prepareForAjaxRequest($form);
PMA_ajaxShowMessage(PMA_messages.strChangingCharset);
$.get($form.attr('action'), $form.serialize() + "&submitcollation=1", function (data) {
$.post($form.attr('action'), $form.serialize() + "&submitcollation=1", function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxShowMessage(data.message);
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get()
}); // end $.post()
}); // end change charset

/**
Expand All @@ -137,7 +137,7 @@ AJAX.registerOnload('db_operations.js', function () {
);
$(this).PMA_confirm(question, $(this).attr('href'), function (url) {
PMA_ajaxShowMessage(PMA_messages.strProcessingRequest);
$.get(url, {'is_js_confirmed': '1', 'ajax_request': true}, function (data) {
$.post(url, {'is_js_confirmed': '1', 'ajax_request': true}, function (data) {
if (typeof data !== 'undefined' && data.success) {
//Database deleted successfully, refresh both the frames
PMA_reloadNavigation();
Expand Down
2 changes: 1 addition & 1 deletion js/db_search.js
Expand Up @@ -85,7 +85,7 @@ function deleteResult(result_path, msg)
/** Load the deleted option to the page*/
$('#sqlqueryform').html('');
var url = result_path;
$.get(url, {'ajax_request': true, 'is_js_confirmed': true},
$.post(url, {'ajax_request': true, 'is_js_confirmed': true},
function (data) {
if (typeof data !== 'undefined' && data.success) {
$('#sqlqueryform').html(data.sql_query);
Expand Down
8 changes: 4 additions & 4 deletions js/db_structure.js
Expand Up @@ -253,7 +253,7 @@ AJAX.registerOnload('db_structure.js', function () {

var params = getJSConfirmCommonParam(this);

$.get(url, params, function (data) {
$.post(url, params, function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxShowMessage(data.message);
// Adjust table statistics
Expand All @@ -272,7 +272,7 @@ AJAX.registerOnload('db_structure.js', function () {
} else {
PMA_ajaxShowMessage(PMA_messages.strErrorProcessingRequest + " : " + data.error, false);
}
}); // end $.get()
}); // end $.post()
}, loadForeignKeyCheckbox); //end $.PMA_confirm()
}); //end of Truncate Table Ajax action

Expand Down Expand Up @@ -316,7 +316,7 @@ AJAX.registerOnload('db_structure.js', function () {

var params = getJSConfirmCommonParam(this);

$.get(url, params, function (data) {
$.post(url, params, function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxShowMessage(data.message);
toggleRowColors($curr_row.next());
Expand All @@ -327,7 +327,7 @@ AJAX.registerOnload('db_structure.js', function () {
} else {
PMA_ajaxShowMessage(PMA_messages.strErrorProcessingRequest + " : " + data.error, false);
}
}); // end $.get()
}); // end $.post()
}, loadForeignKeyCheckbox); // end $.PMA_confirm()
}); //end of Drop Table Ajax action

Expand Down
2 changes: 1 addition & 1 deletion js/db_tracking.js
Expand Up @@ -83,7 +83,7 @@ AJAX.registerOnload('db_tracking.js', function () {
$anchor.PMA_confirm(question, $anchor.attr('href'), function (url) {
PMA_ajaxShowMessage(PMA_messages.strDeletingTrackingData);
AJAX.source = $anchor;
$.get(url, {'ajax_page_request': true, 'ajax_request': true}, AJAX.responseHandler);
$.post(url, {'ajax_page_request': true, 'ajax_request': true}, AJAX.responseHandler);
});
});
});
2 changes: 1 addition & 1 deletion js/functions.js
Expand Up @@ -4415,7 +4415,7 @@ function PMA_createViewDialog($this)
syntaxHighlighter.save();
}
$msg = PMA_ajaxShowMessage();
$.get('view_create.php', $('#createViewDialog').find('form').serialize(), function (data) {
$.post('view_create.php', $('#createViewDialog').find('form').serialize(), function (data) {
PMA_ajaxRemoveMessage($msg);
if (typeof data !== 'undefined' && data.success === true) {
$('#createViewDialog').dialog("close");
Expand Down
4 changes: 2 additions & 2 deletions js/indexes.js
Expand Up @@ -610,7 +610,7 @@ AJAX.registerOnload('indexes.js', function () {

$anchor.PMA_confirm(question, $anchor.attr('href'), function (url) {
var $msg = PMA_ajaxShowMessage(PMA_messages.strDroppingPrimaryKeyIndex, false);
$.get(url, {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
$.post(url, {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxRemoveMessage($msg);
var $table_ref = $rows_to_hide.closest('table');
Expand Down Expand Up @@ -644,7 +644,7 @@ AJAX.registerOnload('indexes.js', function () {
} else {
PMA_ajaxShowMessage(PMA_messages.strErrorProcessingRequest + " : " + data.error, false);
}
}); // end $.get()
}); // end $.post()
}); // end $.PMA_confirm()
}); //end Drop Primary Key/Index

Expand Down
2 changes: 2 additions & 0 deletions js/navigation.js
Expand Up @@ -410,6 +410,7 @@ $(function () {
$(document).on('click', 'a.hideNavItem.ajax', function (event) {
event.preventDefault();
$.ajax({
type: 'POST',
url: $(this).attr('href') + '&ajax_request=true',
success: function (data) {
if (typeof data !== 'undefined' && data.success === true) {
Expand Down Expand Up @@ -457,6 +458,7 @@ $(function () {
var $tr = $(this).parents('tr');
var $msg = PMA_ajaxShowMessage();
$.ajax({
type: 'POST',
url: $(this).attr('href') + '&ajax_request=true',
success: function (data) {
PMA_ajaxRemoveMessage($msg);
Expand Down
8 changes: 4 additions & 4 deletions js/normalization.js
Expand Up @@ -209,7 +209,7 @@ function goTo2NFFinish(pd)
"newTablesName":JSON.stringify(tables),
"createNewTables2NF":1};
$.ajax({
type: "GET",
type: "POST",
url: "normalization.php",
data: datastring,
async:false,
Expand Down Expand Up @@ -254,7 +254,7 @@ function goTo3NFFinish(newTables)
"newTables":JSON.stringify(newTables),
"createNewTables3NF":1};
$.ajax({
type: "GET",
type: "POST",
url: "normalization.php",
data: datastring,
async:false,
Expand Down Expand Up @@ -526,7 +526,7 @@ AJAX.registerOnload('normalization.js', function() {
datastring += "&ajax_request=1&do_save_data=1&field_where=last";
$.post("tbl_addfield.php", datastring, function(data) {
if (data.success) {
$.get(
$.post(
"sql.php",
{
"token": PMA_commonParams.get('token'),
Expand Down Expand Up @@ -604,7 +604,7 @@ AJAX.registerOnload('normalization.js', function() {
dropQuery += 'DROP `' + $(this).val() + '`, ';
});
dropQuery = dropQuery.slice(0, -2);
$.get(
$.post(
"sql.php",
{
"token": PMA_commonParams.get('token'),
Expand Down
12 changes: 6 additions & 6 deletions js/rte.js
Expand Up @@ -388,7 +388,7 @@ RTE.COMMON = {
* the AJAX message shown to the user
*/
var $msg = PMA_ajaxShowMessage(PMA_messages.strProcessingRequest);
$.get(url, {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
$.post(url, {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
if (data.success === true) {
/**
* @var $table Object containing reference
Expand Down Expand Up @@ -437,7 +437,7 @@ RTE.COMMON = {
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get()
}); // end $.post()
}); // end $.PMA_confirm()
},

Expand All @@ -462,7 +462,7 @@ RTE.COMMON = {
* @var $curr_row Object containing reference to the current row
*/
var $curr_row = $anchor.parents('tr');
$.get($anchor.attr('href'), {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
$.post($anchor.attr('href'), {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
returnCount++;
if (data.success === true) {
/**
Expand Down Expand Up @@ -519,7 +519,7 @@ RTE.COMMON = {
PMA_reloadNavigation();
}
}
}); // end $.get()
}); // end $.post()
}); // end drop_anchors.each()
}); // end $.PMA_confirm()
}
Expand Down Expand Up @@ -768,7 +768,7 @@ RTE.ROUTINE = {
* the AJAX message shown to the user
*/
var $msg = PMA_ajaxShowMessage();
$.get($this.attr('href'), {'ajax_request': true}, function (data) {
$.post($this.attr('href'), {'ajax_request': true}, function (data) {
if (data.success === true) {
PMA_ajaxRemoveMessage($msg);
// If 'data.dialog' is true we show a dialog with a form
Expand Down Expand Up @@ -852,7 +852,7 @@ RTE.ROUTINE = {
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get()
}); // end $.post()
}
};

Expand Down
2 changes: 1 addition & 1 deletion js/server_privileges.js
Expand Up @@ -189,7 +189,7 @@ AJAX.registerOnload('server_privileges.js', function () {
.find('select[name="userGroup"]')
.val();
var $message = PMA_ajaxShowMessage();
$.get(
$.post(
'server_privileges.php',
$('#changeUserGroupDialog').find('form').serialize() + '&ajax_request=1',
function (data) {
Expand Down
2 changes: 1 addition & 1 deletion js/server_variables.js
Expand Up @@ -80,7 +80,7 @@ AJAX.registerOnload('server_variables.js', function () {

$mySaveLink.click(function () {
var $msgbox = PMA_ajaxShowMessage(PMA_messages.strProcessingRequest);
$.get($(this).attr('href'), {
$.post($(this).attr('href'), {
ajax_request: true,
type: 'setval',
varName: varName,
Expand Down
2 changes: 1 addition & 1 deletion js/sql.js
Expand Up @@ -160,7 +160,7 @@ AJAX.registerOnload('sql.js', function () {
if ($link.hasClass('formLinkSubmit')) {
submitFormLink($link);
} else {
$.get(url, {'ajax_request': true, 'is_js_confirmed': true}, function (data) {
$.post(url, {'ajax_request': true, 'is_js_confirmed': true}, function (data) {
if (data.success) {
PMA_ajaxShowMessage(data.message);
$link.closest('tr').remove();
Expand Down
12 changes: 6 additions & 6 deletions js/tbl_operations.js
Expand Up @@ -214,7 +214,7 @@ AJAX.registerOnload('tbl_operations.js', function () {

var params = getJSConfirmCommonParam(this);

$.get(url, params, function (data) {
$.post(url, params, function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxRemoveMessage($msgbox);
// Table deleted successfully, refresh both the frames
Expand All @@ -229,7 +229,7 @@ AJAX.registerOnload('tbl_operations.js', function () {
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get()
}); // end $.post()
}, loadForeignKeyCheckbox); // end $.PMA_confirm()
}); //end of Drop Table Ajax action

Expand All @@ -247,7 +247,7 @@ AJAX.registerOnload('tbl_operations.js', function () {
$(this).PMA_confirm(question, $(this).attr('href'), function (url) {

var $msgbox = PMA_ajaxShowMessage(PMA_messages.strProcessingRequest);
$.get(url, {'is_js_confirmed': '1', 'ajax_request': true}, function (data) {
$.post(url, {'is_js_confirmed': '1', 'ajax_request': true}, function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxRemoveMessage($msgbox);
// Table deleted successfully, refresh both the frames
Expand All @@ -262,7 +262,7 @@ AJAX.registerOnload('tbl_operations.js', function () {
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get()
}); // end $.post()
}); // end $.PMA_confirm()
}); //end of Drop View Ajax action

Expand All @@ -281,7 +281,7 @@ AJAX.registerOnload('tbl_operations.js', function () {

var params = getJSConfirmCommonParam(this);

$.get(url, params, function (data) {
$.post(url, params, function (data) {
if ($(".sqlqueryresults").length !== 0) {
$(".sqlqueryresults").remove();
}
Expand All @@ -296,7 +296,7 @@ AJAX.registerOnload('tbl_operations.js', function () {
} else {
PMA_ajaxShowMessage(data.error, false);
}
}); // end $.get()
}); // end $.post()
}, loadForeignKeyCheckbox); // end $.PMA_confirm()
}); //end of Truncate Table Ajax action

Expand Down
4 changes: 2 additions & 2 deletions js/tbl_relation.js
Expand Up @@ -219,7 +219,7 @@ AJAX.registerOnload('tbl_relation.js', function () {

$anchor.PMA_confirm(question, $anchor.attr('href'), function (url) {
var $msg = PMA_ajaxShowMessage(PMA_messages.strDroppingForeignKey, false);
$.get(url, {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
$.post(url, {'is_js_confirmed': 1, 'ajax_request': true}, function (data) {
if (data.success === true) {
PMA_ajaxRemoveMessage($msg);
PMA_commonActions.refreshMain(false, function () {
Expand All @@ -228,7 +228,7 @@ AJAX.registerOnload('tbl_relation.js', function () {
} else {
PMA_ajaxShowMessage(PMA_messages.strErrorProcessingRequest + " : " + data.error, false);
}
}); // end $.get()
}); // end $.post()
}); // end $.PMA_confirm()
}); //end Drop Foreign key
});
6 changes: 3 additions & 3 deletions js/tbl_structure.js
Expand Up @@ -213,7 +213,7 @@ AJAX.registerOnload('tbl_structure.js', function () {
var question = PMA_sprintf(PMA_messages.strDoYouReally, 'ALTER TABLE `' + escapeHtml(curr_table_name) + '` DROP `' + escapeHtml(curr_column_name) + '`;');
$(this).PMA_confirm(question, $(this).attr('href'), function (url) {
var $msg = PMA_ajaxShowMessage(PMA_messages.strDroppingColumn, false);
$.get(url, {'is_js_confirmed' : 1, 'ajax_request' : true, 'ajax_page_request' : true}, function (data) {
$.post(url, {'is_js_confirmed' : 1, 'ajax_request' : true, 'ajax_page_request' : true}, function (data) {
if (typeof data !== 'undefined' && data.success === true) {
PMA_ajaxRemoveMessage($msg);
if ($('.result_query').length) {
Expand Down Expand Up @@ -245,7 +245,7 @@ AJAX.registerOnload('tbl_structure.js', function () {
} else {
PMA_ajaxShowMessage(PMA_messages.strErrorProcessingRequest + " : " + data.error, false);
}
}); // end $.get()
}); // end $.post()
}); // end $.PMA_confirm()
}); //end of Drop Column Anchor action

Expand Down Expand Up @@ -287,7 +287,7 @@ AJAX.registerOnload('tbl_structure.js', function () {
$(this).PMA_confirm(question, $(this).attr('href'), function (url) {
PMA_ajaxShowMessage();
AJAX.source = $this;
$.get(url, {'ajax_request' : true, 'ajax_page_request' : true}, AJAX.responseHandler);
$.post(url, {'ajax_request' : true, 'ajax_page_request' : true}, AJAX.responseHandler);
}); // end $.PMA_confirm()
}); //end Add key

Expand Down
4 changes: 2 additions & 2 deletions js/tbl_tracking.js
Expand Up @@ -80,7 +80,7 @@ AJAX.registerOnload('tbl_tracking.js', function () {
$anchor.PMA_confirm(question, $anchor.attr('href'), function (url) {
PMA_ajaxShowMessage();
AJAX.source = $anchor;
$.get(url, {'ajax_page_request': true, 'ajax_request': true}, AJAX.responseHandler);
$.post(url, {'ajax_page_request': true, 'ajax_request': true}, AJAX.responseHandler);
});
});

Expand All @@ -94,7 +94,7 @@ AJAX.registerOnload('tbl_tracking.js', function () {
$anchor.PMA_confirm(question, $anchor.attr('href'), function (url) {
PMA_ajaxShowMessage();
AJAX.source = $anchor;
$.get(url, {'ajax_page_request': true, 'ajax_request': true}, AJAX.responseHandler);
$.post(url, {'ajax_page_request': true, 'ajax_request': true}, AJAX.responseHandler);
});
});
});

0 comments on commit f08bc1a

Please sign in to comment.