diff --git a/static/js/src/app/sending_profiles.js b/static/js/src/app/sending_profiles.js index 043bd1e5..d4874b8e 100644 --- a/static/js/src/app/sending_profiles.js +++ b/static/js/src/app/sending_profiles.js @@ -307,7 +307,7 @@ $(document).ready(function () { dismissSendTestEmailModal() }) // Code to deal with custom email headers - $("#headersForm").on('submit', function () { + $("#addCustomHeader").on('click', function () { headerKey = $("#headerKey").val(); headerValue = $("#headerValue").val(); @@ -316,7 +316,8 @@ $(document).ready(function () { } addCustomHeader(headerKey, headerValue); // Reset user input. - $("#headersForm>div>input").val(''); + $("#headerKey").val(''); + $("#headerValue").val(''); $("#headerKey").focus(); return false; }); diff --git a/templates/sending_profiles.html b/templates/sending_profiles.html index 97f9f37f..0959f830 100644 --- a/templates/sending_profiles.html +++ b/templates/sending_profiles.html @@ -44,27 +44,29 @@