var myAjax = function(arg) { var opt = $.extend({}, $.ajaxSettings, arg); opt.success = (function(func) { return function(data, statusText, jqXHR) { console.log('success時の共通処理 ...'); if (func) { func(data, statusText, jqXHR); } }; })(opt.success); opt.error = (function(func) { return function(jqXHR, statusText, errorThrown) { console.log('error時の共通処理 ...'); if (func) { func(jqXHR, statusText, erro
