Ajax success but I can't insert data into MySQL database
<p><strong>SETUP ENVIROMENT</strong> : 000webhost</p>

<p>I'm using chrome's developer tool to track my ajax request through a simple button ("Turn on") and It seems working fine from javascript side.<br>
(My webpage currently: <a href="http://estacionamiento.site88.net/" rel="nofollow">here</a>)  </p>

<p>My problem is that even though ajax make a success call to 'ajax.php', once is called It doesn't insert anything to my table 'dogcare' mysql database.
<a href="http://imgur.com/a/TfVCz" rel="nofollow">click here to see my table</a></p>

<p>This is index.php</p>

<pre class="lang-js prettyprint-override"><code>&lt;!DOCTYPE html&gt;
&lt;html&gt;
&lt;head&gt;
    &lt;meta charset="utf-8"&gt;
    &lt;title&gt;Estacionamiento&lt;/title&gt;
    &lt;link rel="stylesheet" type="text/css" href="style.css"&gt;
    &lt;meta name="viewport" content="width=device-width"&gt;
&lt;/head&gt;
&lt;body&gt;
    &lt;h1 class="title"&gt; Dog Care &lt;/h1&gt;
    &lt;script src="https://meet.jit.si/external_api.js"&gt;&lt;/script&gt;
    &lt;div class="chart"&gt;
      &lt;div class="video"&gt;
       &lt;script&gt;
          var domain = "meet.jit.si";
          var room = "dogcare";
          var width = 700;
          var height = 700;
          var api = new JitsiMeetExternalAPI(domain, room, width, height);
        &lt;/script&gt;
      &lt;/div&gt;
      &lt;div class="buttons"&gt;
      &lt;input type = "submit" name ="on" id="on" value = "Turn On"&gt;
      &lt;input type = "submit" name ="off" id="off" value = "Turn Off"&gt;
      &lt;/div&gt;
    &lt;/div&gt;

  &lt;script src="js/jQuery.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript"&gt;
      $(document).ready(function(){
        alert("jquery is working");
              $("#on").click(function(){
                  var accion = "feed";
                  var flagtime = "no";
                  var lunchtime = "13:00";
                  $.ajax({
                      url: "ajax.php",
                      type: "POST",
                      async: false,
                      data: {
                          "done": 1,
                          "accion": accion,
                          "flagtime": flagtime,
                          "lunchtime": lunchtime
                      },
                      success: function(data){
                        alert("ajax successfull");
                      }
                  })
              })

      })


  &lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p>This ajax.php</p>

<pre><code>&lt;?php

    if (isset($_POST['done'])) {
        $link = new mysqli("localhost", "myuser", "mypassword", "my_db");

        if (mysqli_connect_errno()) {
                printf("Connect failed: %s\n", mysqli_connect_error());
                exit();
        }
        $accion = $_POST['accion'];
        $flagtime = $_POST['flagtime'];
        $lunchtime = $_POST['lunchtime'];

        mysqli_query($link, "INSERT INTO 'dogcare' ('accion', 'flagtime','lunchtime') VALUES ('{$accion}', '{$flagtime}','{$lunchtime}')");
        exit();
    }
?&gt;
</code></pre>



<p>I would appreciate any help and if anyone can tell me how to check if there's a connection to my database ( I'm quite sure It is but I'd like to see "server connection: OK" or something like that ). Also I'm quite new to php language.</p>

<p>P.S: BTW Button turn off doesn't do anything yet.<br>
     I let 2 alerts to see if jQuery is working and if there's an ajax call.</p>