-
Bug
-
Resolution: Fixed
-
Minor
-
3.0, 3.1
-
MOODLE_30_STABLE, MOODLE_31_STABLE
-
MOODLE_30_STABLE
-
MDL-52136-master -
While creating some tests for MDL-52126 I detected that sometimes there were some placeholders in the resulting email body not being replaced. Example of borked results with both user lastname and course shortname having a double quote:
101'" -> Forums -> Moodle Forum'" -> Hello Moodle'"
|
http://www.example.com/moodle/mod/forum/discuss.php?d=285000
|
Hello Moodle'"
|
by {$a->name} - {$a->date}
|
---------------------------------------------------------------------
|
Welcome to Moodle'"
|
|
Attachment example.txt:
|
http://www.example.com/moodle/pluginfile.php/237006/mod_forum/attachment/286000/example.txt
|
|
---------------------------------------------------------------------
|
This not is not a copy of a message posted on the {$a->coursename} website.
|
|
To reply click on this not link: {$a->replylink}
|
- I tested backporting the test to 29_STABLE and it worked there.
- I tested without the double quotes and then it worked.
To reproduce:
A) method A: Create a user fullname or a course shortname containing double quotes and create a forum post with them. Mail (text or html) will arrive with those placeholders not replaced (in the text part of the multipart).
B) method B: Uncomment the TODO lines in mod/forum/tests/mail_test.php and the test will fail showing the results above.
- caused a regression
-
MDL-66542 "quote" Mustache helper only escapes first quote in JS
-
- Closed
-
- Discovered while testing
-
MDL-52126 Mustache template over-escaping in forum emails
-
- Closed
-
- is a regression caused by
-
MDL-49682 Forum email template is not editable by themes
-
- Closed
-
- is duplicated by
-
MDL-52563 Forum Digest summary email contains a semi-colon
-
- Closed
-