While looking at the empty nick issue (and the earlier password related tweaks) I noticed there where quite a few fields which did not present user feedback in a clear manner. Most likely many forms are still configured for whatever "old" CSS styling was used before bootstrap.
This PR adds a small helper where we can add some default FormHelper configuration to make it work with Bootstrap field validations by default. Didn't find a good way to "include" it globally, in CakePHP2 so for now it's manually included in relevant forms. As a bonus, this also lets us clean up a lot of boilerplate from form/input related templates.
Changes:
A lot clearer indication of validation errors on profile related forms
Adds shared useBootstrapForms method which configures FormHelper with some bootstrap-friendly defaults
Updates Profile related forms to use the shared defaults (to show how it's used, and make it easier to adopt other places later)
While looking at the empty nick issue (and the earlier password related tweaks) I noticed there where quite a few fields which did not present user feedback in a clear manner. Most likely many forms are still configured for whatever "old" CSS styling was used before bootstrap.
This PR adds a small helper where we can add some default FormHelper configuration to make it work with Bootstrap field validations by default. Didn't find a good way to "include" it globally, in CakePHP2 so for now it's manually included in relevant forms. As a bonus, this also lets us clean up a lot of boilerplate from form/input related templates.
Changes:
useBootstrapForms
method which configures FormHelper with some bootstrap-friendly defaults