Having issues displaying an alert to the response when sending email using mandrill. The email send successfully and I can see it in the Mandrill API log.. here is the response return
[
{
"email": "a href="mailto:bob@aol.com" rel="nofollow"bob@aol.com/a",
"status": "sent",
"id": "91585cf913af4ff487394075111021ef",
"reject_reason": null
},
{
"email": "a href="mailto:sally@ail.com" rel="nofollow"sally@ail.com/a",
"status": "sent",
"id": "fc26c8e30f974e458f204a70ef487350",
"reject_reason": null
}
]
This is what I am trying,
var response = JSON.parse(jqXHR.responseText);
if (response.return[1] == 'sent')
{
alert ('Email sent.');
}