title: php query in database doesn't work
body: <p>Hello guys i tried to add into database some values and it's not working.I tried everything but no.
  What should i do? the name of the table is "credit".
  Can you help me to rezolv this problem?</p>
  
  <pre><code>&lt;tr&gt;
      &lt;td&gt;&lt;input class="form-control" placeholder="nr" name="nr" type="text" autofocus&gt;&lt;/td&gt;
      &lt;td&gt;&lt;input class="form-control" placeholder="suma" name="suma" type="text" autofocus&gt;&lt;/td&gt;   
      &lt;td&gt;&lt;input class="form-control" placeholder="rate" name="rate" type="text" autofocus&gt;&lt;/td&gt;
      &lt;td&gt;&lt;input class="form-control" placeholder="dobanda" name="dobanda" type="text" autofocus&gt;&lt;/td&gt;    
      &lt;td&gt;&lt;button class="btn btn-success" value="adaugare"&gt;Adaugare credit&lt;/button&gt;&lt;/a&gt;&lt;/td&gt;   
  &lt;/tr&gt;
  &lt;/table&gt;
  &lt;/div&gt;
  &lt;/div&gt;
  
  &lt;?php if(isset($_POST['adaugare']))
      {
          $nr=$_POST['nr'];
          $suma=$_POST['suma'];
          $rate=$_POST['rate'];
          $dobanda=$_POST['dobanda'];
  
          if($nr=='')
          {
  
              echo"&lt;script&gt;alert('Introdu numar')&lt;/script&gt;";
              exit();
          }
  
          if($suma=='')
          {
  
              echo"&lt;script&gt;alert('Introdu suma')&lt;/script&gt;";
              exit();
          }
          if($rate=='')
          {
              echo"&lt;script&gt;alert('Introdu rate')&lt;/script&gt;";
              exit();
          }
          if($dobanda=='')
          {
              echo"&lt;script&gt;alert('Introdu dobanda')&lt;/script&gt;";
              exit();
          }
          $id=$_SESSION['id'];
          $insert_credit="insert into credit VALUE ('$nr','$id','$suma','$rate','$dobanda')";
          mysqli_query($dbcon,$insert_credit);
  
  
      }
  </code></pre>