|
@@ -95,6 +95,8 @@
|
|
|
$(document).ready(function() {
|
|
$(document).ready(function() {
|
|
|
$('#defaultForm').bootstrapValidator({
|
|
$('#defaultForm').bootstrapValidator({
|
|
|
message: 'This value is not valid',
|
|
message: 'This value is not valid',
|
|
|
|
|
+ feedbackIcons: true,
|
|
|
|
|
+// live: 'disabled',
|
|
|
fields: {
|
|
fields: {
|
|
|
username: {
|
|
username: {
|
|
|
message: 'The username is not valid',
|
|
message: 'The username is not valid',
|
|
@@ -105,6 +107,10 @@ $(document).ready(function() {
|
|
|
remote: {
|
|
remote: {
|
|
|
url: 'remote.php',
|
|
url: 'remote.php',
|
|
|
message: 'The username is not available'
|
|
message: 'The username is not available'
|
|
|
|
|
+ },
|
|
|
|
|
+ different: {
|
|
|
|
|
+ field: 'password',
|
|
|
|
|
+ message: 'The username and password can\'t be the same as each other'
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
@@ -130,6 +136,10 @@ $(document).ready(function() {
|
|
|
identical: {
|
|
identical: {
|
|
|
field: 'confirmPassword',
|
|
field: 'confirmPassword',
|
|
|
message: 'The password and its confirm are not the same'
|
|
message: 'The password and its confirm are not the same'
|
|
|
|
|
+ },
|
|
|
|
|
+ different: {
|
|
|
|
|
+ field: 'username',
|
|
|
|
|
+ message: 'The password can\'t be the same as username'
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|