diff options
| author | Nicolas Lempereur <nle@odoo.com> | 2015-06-30 10:12:42 +0200 |
|---|---|---|
| committer | Nicolas Lempereur <nle@odoo.com> | 2015-06-30 12:21:07 +0200 |
| commit | 6316bce8fea83aab822d04f20b0d5f8b41608014 (patch) | |
| tree | b11db3ccb9c4ab6f36b4c8dbcfaafaf238da24fa /addons | |
| parent | 55881d3ec31a2655fbed9fa68ff212c83675b54a (diff) | |
[FIX] website_mail: special case for css splitting
The css of a mail is inlined as best as possible for the mail sending.
Previously, if there was a selector like .ch[onclick="ga(this,event)"]
the simple splitting would split in the middle and get one erroneous
selector (which then would trigger an error).
With his commit, rules containing " or ' are ignored.
opw-643548
Diffstat (limited to 'addons')
| -rw-r--r-- | addons/website_mail/static/src/js/website_email_designer.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/addons/website_mail/static/src/js/website_email_designer.js b/addons/website_mail/static/src/js/website_email_designer.js index b2ce7286281..4bc778c2130 100644 --- a/addons/website_mail/static/src/js/website_email_designer.js +++ b/addons/website_mail/static/src/js/website_email_designer.js @@ -240,7 +240,9 @@ selectorText.indexOf(":after") === -1 && selectorText.indexOf(":active") === -1 && selectorText.indexOf(":link") === -1 && - selectorText.indexOf("::") === -1) { + selectorText.indexOf("::") === -1 && + selectorText.indexOf("\"") === -1 && + selectorText.indexOf("'") === -1) { var st = selectorText.split(/\s*,\s*/); for (var k=0; k<st.length; k++) { rulesCache.push({ |
