I receive a Json output from PHP page like this

```html
[{"x":"2018-03-20","y":1,"z":7},{"x":"2018-03-22","y":31,"z":5},{"x":"2018-03-25","y":7,"z":21}]
```

How can I loop over the results so that I would have access to each of the elements? I have tried something like below but this does not seem to be working.

```js
function LoadResultMorris()
{
$.ajax({
    type: "POST",
    url: 'admin/data.php',
    data: {type1: 'search1'},
    success: function(data){
$.each(data.data, function(key, value) {
    alert(data[key]);
    alert(data[value]);
});
        }
});

}
```