Why I am getting no data through JQuery?

Why I am getting no data through JQuery?

Hi,

I am using below code to get list of birthdays. I have one birthday in my database on 23/9 and I am able to see it when I check the URL:


but getting nothing when I check this URL:


The only difference between both is ( populate_birthday_GET):

  1. $day = $_GET["day"];
  2. $month = $_GET["month"];

and ( populate_birthday):

  1. $day = $_POST["day"];
  2. $month = $_POST["month"];


Here is my code:

  1. var formData = new FormData();

  2. var current_date = new Date();

  3. // formData.append("day", current_date.getDate() + 1);
  4. // formData.append("month", current_date.getMonth());

  5. formData.append("day", 23);
  6. formData.append("month", 9);

  7. $.ajax({
  8.     type: "POST",
  9.     url: "https://www.softnames.com/the_blessed_tree/ws/populate_birthday.php",
  10.     data: formData,
  11.     async: true,
  12.     dataType: "json",
  13.     processData: false,
  14.     beforeSend: function (data) {
  15.         // viewModel.loadPanelVisible(true);
  16.     },
  17.     success: function (data) {
  18.         table = data.Birthday;
  19.         console.log(data);
  20.     },
  21.     error: function () {
  22.             return;
  23.         });
  24.     }
  25. });