I have a form that is hidden when the page loads, but displayed with an addClass function:
jQuery(".talk-button").click(function () {
jQuery("#lets-talk").addClass('on');
});
This is working properly, as is a cancel button added as an html element in the form that hides the div again:
jQuery(".talk-cancel").click(function () {
jQuery("#lets-talk").removeClass('on');
});
The form is submitted with AJAX and the notification that is displayed also shows a button with the .talk-cancel class, but that button isn't properly closing the window. I don't see any errors in my dev console.
Any thoughts on why the AJAX form submit might be preventing my .removeClass function from working properly?