Basically my code works like that:

1\* Send the first line.
2\* Get the response and sent it back.
3\* remove one line and check the next line which will be the first line.

However in my code the data does not change at all in the whole process it checks only the first line again and again this is the code that i tried:

```
var resource = $('#resource').val().replace(/[\n\r](?!\w)/gi, "").split("\n");  

$.each(resource , function() {
  $.ajax({
    type:'POST',
    url :'curl_check.php',
    data: 'email='+resource[0],
    success: function(data) {
      alert(resource);
      resource.splice(0, 1);
      $('#resource').val(resource.join("\n"))
    }   
  });
});

```

Basically even the line is removed from the text-area the values still the same.