-
Bug
-
Resolution: Deferred
-
Minor
-
None
-
2.6.2
-
MOODLE_26_STABLE
Issue Description
Certain pages that use YUI trees in Moodle fail to validate because an invalid HTML attribute called yuiconfig is used in LI tags. Although I am only reporting it here for the Assignment module, the issue exists in the following sections of code:
- /blocks/private_files/renderer.php
- /mod/assign/renderer.php
- /mod/assignment/renderer.php
- /mod/wiki/renderer.php
- /user/renderer.php
Expected Behaviour
The markup be written in such a way that the HTML code pass W3C HTML validation.
Steps to Reproduce
1) Create an assignment activity in a course.
2) Upload a file on the assignment page.
3) Notice that the HTML contains code similar to the following:
<li yuiConfig='{"type":"html"}'>
... which was generated by Moodle PHP code similar to the following:
$result .= '<li yuiConfig=\'' . json_encode($yuiconfig) . '\'>'
Standard
WCAG 2.0 4.1.1 - Parsing
http://www.w3.org/TR/2013/NOTE-UNDERSTANDING-WCAG20-20130905/ensure-compat-parses.html
G134: Validating Web pages
http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G134
- will be (partly) resolved by
-
MDL-32736 Migrate away from YUI2 treeview
-
- Development in progress
-