diff --git a/common/static/common/js/utils/edx.utils.validate.js b/common/static/common/js/utils/edx.utils.validate.js
index 6483eace9d..d15a249922 100644
--- a/common/static/common/js/utils/edx.utils.validate.js
+++ b/common/static/common/js/utils/edx.utils.validate.js
@@ -21,7 +21,7 @@
var _fn = {
validate: {
- template: _.template('
<%- content %>'),
+ template: _.template('><%- content %>'),
msg: {
email: gettext("The email address you've provided isn't formatted correctly."),
@@ -133,7 +133,8 @@
context,
content,
customMsg,
- liveValidationMsg;
+ liveValidationMsg,
+ suppressAttr;
_.each(tests, function(value, key) {
if (!value) {
@@ -159,8 +160,14 @@
content = _.sprintf(_fn.validate.msg[key], context);
}
+ suppressAttr = '';
+ if (['username', 'email'].indexOf($el.attr('name')) > -1) {
+ suppressAttr = 'data-hj-suppress';
+ }
+
txt.push(_fn.validate.template({
- content: content
+ content: content,
+ suppressAttr: suppressAttr
}));
}
});
diff --git a/lms/static/js/student_account/views/RegisterView.js b/lms/static/js/student_account/views/RegisterView.js
index 3953f27393..95b668a235 100644
--- a/lms/static/js/student_account/views/RegisterView.js
+++ b/lms/static/js/student_account/views/RegisterView.js
@@ -423,6 +423,9 @@
$label.addClass(indicator);
$req.addClass(indicator);
$icon.addClass(indicator + ' ' + icon);
+ if (['username', 'email'].indexOf($el.attr('name')) > -1) {
+ $tip.addClass(' data-hj-suppress');
+ }
$tip.text(msg);
},