I am surprised that No error message reflect if the user has already subscribed the newsletter. No help in the Theme>Language
I tried with the custom code but it also didn’t change anything.
my custom code is here :
// Newsletter Already subscribed user - Error Message
var live_url = window.location.href;
var result = live_url.includes('form_type=customer');
var input_val = document.querySelector('[id*="NewsletterForm"]').value.length;
//var input_val = document.querySelector('Contact_163955177715547d60').value.length;
//var input_val = document.querySelector('[id*="Contact_"]').value.length;
if(result && input_val != 0){
const add_ele = document.createElement("h3");
add_ele.innerText = "You have already subscribed!";
document.querySelector('.newsletter-form__field-wrapper').appendChild(add_ele);
add_ele.classList.add('newsletter_already_subscribe','newsletter-form__message','form__message');
}
Please help if anyone achieved it already. My theme is debut theme