send test mail when clicking an a link with class 'sendtestmail'

This commit is contained in:
Uwe Steinmann 2013-09-13 14:53:45 +02:00
parent 7b1663479d
commit 070c68fd10

View File

@ -140,6 +140,25 @@ $(document).ready( function() {
} }
); );
}); });
$('a.sendtestmail').click(function(ev){
ev.preventDefault();
$.ajax({url: '../op/op.Ajax.php',
type: 'GET',
dataType: "json",
data: {command: 'testmail'},
success: function(data) {
console.log(data);
noty({
text: data.msg,
type: (data.error) ? 'error' : 'success',
dismissQueue: true,
layout: 'topRight',
theme: 'defaultTheme',
timeout: 1500,
});
}
});
});
}); });
function allowDrop(ev) { function allowDrop(ev) {