$("form").submit(function (e) {
e.preventDefault();
var thanksWindow = window.open('thank-you.html', '_blank');
var openThanksWindowFunction = function() {
thanksWindow.location;
}
$.ajax({
type: "POST",
url: "send.php",
data: th.serialize()
}).done(function () {
th.trigger("reset");
openThanksWindowFunction();
});
return false;
});