anchor.diff:            }
           }
         }
  -      $check.removeClass("hidden");
  +      $success.removeClass("hidden");
  +      $failure.addClass("hidden");
  +      $submit.addClass("hidden");
  +    }).fail(function(_, msg, errorText) {
  +      $success.addClass("hidden");
  +      $failure.removeClass("hidden").attr('title', errorText).tooltip('fixTitle');
  +      $submit.removeClass("hidden");
       });
       return false; // prevents normal behaviour
     }).map(function() {
  
positive.code:               data: {toggle: "toggle", on: "Reenroll", off: noopAction}} %>
          <% end %>
        </td>
        <td><i id="success_<%= type %>_<%= r.id %>" style="font-size: 150%;"
               class="hidden text-success glyphicon glyphicon-ok"
               data-toggle="tooltip" title="Registration information saved"
               ></i></td>
        <!-- <td><%= submit_tag "Save", {form: "reg_#{type}_#{r.id}", class: "btn btn-default"} %></td> -->
      </tr>
      <% end %>
    </tbody>
  
negative.code:       $("#success_" + $form.find("input[name='id']").val()).addClass("hidden");
      });
    });
    $("select, input[type!='submit']").change(function(e) {
       $(e.target).parents("tr").find("input[type='submit']").attr("disabled", false).removeClass("hidden");
       $(e.target).parents("tr").find("i.text-success").addClass("hidden");
       $(e.target).parents("tr").find("i.text-danger").addClass("hidden");
    });
  </script>
  