1

Total noob here. I'm using Angularjs 1.30 and trying to get confirm password to work. I want it such that if the "password" and "confirm_password" input fields match and validate, if I then modify either of the two fields, the form will no longer be valid.

I think Dominic Watson gave an answer in password-check directive in angularjs, but pasting his module it into my .js and including it in my var app = angular.module('myapp', ['validators']) doesn't seem to work because...well, I don't know how to attach/use modules... (so if you can explain how I can use the modules like the one he posted into my own project, that would be great too!)

I've tried most everything I could find, and as Dominic pointed out, the problem seems to be that in Angular 1.30, "invalid inputs don't write to ngModel"

Community
  • 1
  • 1
gunit
  • 3,700
  • 4
  • 31
  • 42

1 Answers1

1

Does app lives in my.js? If you have many js files, you have to build them using some build tool, like gulp. I can't say why it does't work for you without seeing your code. I think you should publish it and show us. You can try my solution. It does pretty much the same.

Igor Yalovoy
  • 1,715
  • 1
  • 17
  • 22