-
Improvement
-
Resolution: Won't Do
-
Minor
-
None
-
2.9.7, 3.0.7, 3.1.3, 3.2
-
MOODLE_29_STABLE, MOODLE_30_STABLE, MOODLE_31_STABLE, MOODLE_32_STABLE
I don't know how to solve this, but a theme is allows to override a render method to change the context before sending it to a mustache template. If it does this, the changed context will only apply when the render_x method is called which means php only.
If a template is rendered by both php and javascript the themer needs to do one of:
1. Override the template and gracefully handle either the modified, or the original context.
2. Find out where the template is used and use a different template for the javascript version.
It would be best if a theme could change the context in php and have it apply to php and javascript. This is not possible because the function signatures of the webservices are "fixed" - so the modified data returned from a webservice function would trigger an error.
- has been marked as being related by
-
MDL-57333 Cannot add classes to pix_icon in boost properly
-
- Closed
-