function getParameterByName(name) {
const results = new RegExp('[?&]' + name + '=([^]*)').exec(window.location.href);
return results ? decodeURIComponent(results[1].replace(/\+/g, ' ')) : null;
}
const name = getParameterByName('name');
const email = getParameterByName('email');
const phone = getParameterByName('phone')
// Display the message if both parameters are available
if (name && email) {
$('.tanksMsgBlock p')
.html(`Thank you, ${name}! We will contact you at ${email}.`);
} else {
// Display a generic message or handle the case where parameters are missing
$('.tanksMsgBlock p')
.html('Thank you for reaching out! We will be in touch shortly.');
}