diff options
author | Matthew Somerville <matthew@mysociety.org> | 2012-05-14 15:24:18 +0100 |
---|---|---|
committer | Matthew Somerville <matthew@mysociety.org> | 2012-05-14 15:24:18 +0100 |
commit | 6f80cdbf67468e50d0ca47a8cfbb4b593585fb56 (patch) | |
tree | da593251fe1656d7c34263bf2f2e18b8c00ae7a5 | |
parent | 65c9942888571fcd81e915748a4426f69c97dea1 (diff) |
Include submit button input for JS submission, so that server directs correctly.
-rw-r--r-- | web/cobrands/fixmystreet/fixmystreet.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/web/cobrands/fixmystreet/fixmystreet.js b/web/cobrands/fixmystreet/fixmystreet.js index f73290b7b..9d5151189 100644 --- a/web/cobrands/fixmystreet/fixmystreet.js +++ b/web/cobrands/fixmystreet/fixmystreet.js @@ -503,6 +503,7 @@ $.fn.drawer = function(id, ajax) { $('.container').on('click', '#alert_email_button', function(e){ e.preventDefault(); var form = $('<form/>').attr({ method:'post', action:"/alert/subscribe" }); + form.append($('<input name="alert" value="Subscribe me to an email alert" type="hidden" />')); $('#alerts input[type=text], #alerts input[type=hidden], #alerts input[type=radio]:checked').each(function() { var $v = $(this); $('<input/>').attr({ name:$v.attr('name'), value:$v.val(), type:'hidden' }).appendTo(form); |