0
Do you have any way to send parameter to Servlet and receive a json in the same AJAX Function? Example of what I need:
function UpdateGrafico(){
$(function () {
//---------------------
//aqui preciso enviar uma data para o servlet realizar um select
$.ajax({
data: "",
dataType: 'json',
url: './GetValores',
type: 'POST',
success: function(data){
//recebe os dados json e atualiza pagina
});
}
I need this way because on the JSP page there is a button and when I click on it, a date will be taken that the user has selected, and used this date for a select on Servlet, which will return the data to update a chart on the JSP page.