title: Jquery simple Ajax Post PHP not working
body: <p>I have a simple code but is not working. I want to create a more complex function but I just need the basic structure.</p>
  
  <p>HTML</p>
  
  <pre><code>&lt;span class="cleanreport"&gt;Delete Record&lt;/span&gt;
  </code></pre>
  
  <p>Javascript:</p>
  
  <pre><code>$( ".cleanreport" ).click(function() {
  
  var token = "test";
  
  $.ajax({
  data: {"data": token},
  type: "post",
  url: "clean.php",
  success: function (data) {
  console.log(data);
  $('.test').html(data);
    }
      });
  });
  </code></pre>
  
  <p>PHP clean.php</p>
  
  <pre><code>$data = $_POST['data'];
  echo $data;
  </code></pre>
  
  <p>What I am doing wrong?</p>