Sha256: c05a70d7054b81e9883c027b9993c40157c0fe0012263de15d6388e6af4dc369

Contents?: true

Size: 1.2 KB

Versions: 14

Compression:

Stored size: 1.2 KB

Contents

%h1 Change Your Password

.form
  = form_for resource do |f|
    -if resource.errors.any?
      #errorExplanation
        %h2= "#{pluralize(resource.errors.count, "error")} prohibited this change:"
        %ul
          - resource.errors.full_messages.each do |msg|
            %li= msg
    .field
      .fieldName Old Password:
      = f.password_field :old_password, :id=>"old_password"
    .field
      .fieldName New Password:
      = f.password_field :password, :id=>"password"
    .field
      .fieldName Confirm Password:
      = f.password_field :password_confirmation
    .submit= f.submit "Change Password"

:css
  .extra_form_data {
    display: none;
  }

= content_for :head do
  = javascript_include_tag 'jquery.validate'


:javascript
  var checkingPassword = true;
  $(function(){
  jQuery.validator.addMethod("verify_user", function(value, element, params) {
  //alert($(element).attr('data-verify-user-path'));
  return $.ajax({
  async: false,
  url: $(element).attr('data-verify-user-path')+ '?password='+value
  }).responseText == "true";
  }, "Password is incorrect.");

  $('form').validate({onkeyup: function(element) {}});
  $('#old_password').rules("add", {verify_user : true, alphanumeric: true})
  });

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
wheels-0.1.13 app/views/users/edit.html.haml
wheels-0.1.12 app/views/users/edit.html.haml
wheels-0.1.10 app/views/users/edit.html.haml
wheels-0.1.9 app/views/users/edit.html.haml
wheels-0.1.8 app/views/users/edit.html.haml
wheels-0.1.7 app/views/users/edit.html.haml
wheels-0.1.6 app/views/users/edit.html.haml
wheels-0.1.5 app/views/users/edit.html.haml
wheels-0.1.4 app/views/users/edit.html.haml
wheels-0.1.3 app/views/users/edit.html.haml
wheels-0.1.2 app/views/users/edit.html.haml
wheels-0.1.1 app/views/users/edit.html.haml
wheels-0.1.0 app/views/users/edit.html.haml
wheels-0.0.49 app/views/users/edit.html.haml