summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
authorOlivier Dony <odo@openerp.com>2015-07-01 17:49:56 +0200
committerOlivier Dony <odo@openerp.com>2015-07-01 17:58:28 +0200
commite3bd2a591491c48e805b66d5ee9f898bab4b5432 (patch)
tree7965e6643f0bd48465ebee2b2c5fa8ffb79e28c4 /addons
parentd0735fc55713117e8470c1036a9fe9dd947ea8be (diff)
[FIX] web_calendar, website: avoid rendering errors with special characters
Diffstat (limited to 'addons')
-rw-r--r--addons/web_calendar/static/src/js/web_calendar.js6
-rw-r--r--addons/website/static/src/js/website.snippets.animation.js2
2 files changed, 4 insertions, 4 deletions
diff --git a/addons/web_calendar/static/src/js/web_calendar.js b/addons/web_calendar/static/src/js/web_calendar.js
index f9d108b90f7..87554e52e1d 100644
--- a/addons/web_calendar/static/src/js/web_calendar.js
+++ b/addons/web_calendar/static/src/js/web_calendar.js
@@ -544,7 +544,7 @@ openerp.web_calendar = function(instance) {
attendee_showed += 1;
if (attendee_showed<= MAX_ATTENDEES) {
if (self.avatar_model !== null) {
- the_title_avatar += '<img title="' + self.all_attendees[the_attendee_people] + '" class="attendee_head" \
+ the_title_avatar += '<img title="' + _.escape(self.all_attendees[the_attendee_people]) + '" class="attendee_head" \
src="/web/binary/image?model=' + self.avatar_model + '&field=image_small&id=' + the_attendee_people + '"></img>';
}
else {
@@ -552,12 +552,12 @@ openerp.web_calendar = function(instance) {
tempColor = (self.all_filters[the_attendee_people] !== undefined)
? self.all_filters[the_attendee_people].color
: (self.all_filters[-1] ? self.all_filters[-1].color : 1);
- the_title_avatar += '<i class="fa fa-user attendee_head color_'+tempColor+'" title="' + self.all_attendees[the_attendee_people] + '" ></i>';
+ the_title_avatar += '<i class="fa fa-user attendee_head color_'+tempColor+'" title="' + _.escape(self.all_attendees[the_attendee_people]) + '" ></i>';
}//else don't add myself
}
}
else {
- attendee_other += self.all_attendees[the_attendee_people] +", ";
+ attendee_other += _.escape(self.all_attendees[the_attendee_people]) +", ";
}
}
);
diff --git a/addons/website/static/src/js/website.snippets.animation.js b/addons/website/static/src/js/website.snippets.animation.js
index f68097c3f69..e184e70e509 100644
--- a/addons/website/static/src/js/website.snippets.animation.js
+++ b/addons/website/static/src/js/website.snippets.animation.js
@@ -152,7 +152,7 @@
website.snippet.animationRegistry.media_video = website.snippet.Animation.extend({
selector: ".media_iframe_video",
start: function () {
- this.$target.html('<div class="css_editable_mode_display">&nbsp;</div><iframe src="'+this.$target.data("src")+'" frameborder="0" allowfullscreen="allowfullscreen"></iframe>');
+ this.$target.html('<div class="css_editable_mode_display">&nbsp;</div><iframe src="'+_.escape(this.$target.data("src"))+'" frameborder="0" allowfullscreen="allowfullscreen"></iframe>');
},
});
})();