Moodle

The moodle html editor is still using font tags rather than styles, which breaks accessibility testing.

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: 1.8.11, 1.9.7
  • Fix Version/s: 2.0
  • Component/s: Accessibility, Filters
  • Labels:
    None
  • Environment:
    Moodle 1.8 (original first release) on Centos Linux 4.4 with PHP 5.1.6 and MySQL 5.0.20
  • Database:
    Any
  • Difficulty:
    Easy
  • Affected Branches:
    MOODLE_18_STABLE, MOODLE_19_STABLE
  • Fixed Branches:
    MOODLE_20_STABLE

Description

A client reports that the editor is still creating html that uses <font> tags - this breaks the accessibility compliance. Any thoughts?

Issue Links

Activity

Hide
Michael Spall added a comment -

This also causes problems if you want to use the Moodle Tidy Filter in 1.8 because the font tags are stripped out by the Tidy filter.

Show
Michael Spall added a comment - This also causes problems if you want to use the Moodle Tidy Filter in 1.8 because the font tags are stripped out by the Tidy filter.
Hide
Eloy Lafuente (stronk7) added a comment -

Updated versions and pasted from recent duplicate of this (MDL-21743):

Hi all,

main problem here is that the tidy filter is aimed to produce correct XHTML results and FONT tags aren't allowed there, hence the default setting defined to drop them. And there are a bunch of Moodle installations requiring that, so we cannot, simply, change current behavior.

Perhaps it would be more interesting to, alternatively:

1) Allow configuration of the filter, so ppl can decide (using current settings as default).
2) Instead of setting it to "no", perhaps enabling the "clean" option could be interesting, as far as it uses to convert those tags into proper css styles/rules. Note I haven't tested it, just read the documentation at: http://tidy.sourceforge.net/docs/quickref.html#clean

Sounds easily achievable IMO, ciao

Show
Eloy Lafuente (stronk7) added a comment - Updated versions and pasted from recent duplicate of this (MDL-21743): Hi all, main problem here is that the tidy filter is aimed to produce correct XHTML results and FONT tags aren't allowed there, hence the default setting defined to drop them. And there are a bunch of Moodle installations requiring that, so we cannot, simply, change current behavior. Perhaps it would be more interesting to, alternatively: 1) Allow configuration of the filter, so ppl can decide (using current settings as default). 2) Instead of setting it to "no", perhaps enabling the "clean" option could be interesting, as far as it uses to convert those tags into proper css styles/rules. Note I haven't tested it, just read the documentation at: http://tidy.sourceforge.net/docs/quickref.html#clean Sounds easily achievable IMO, ciao
Hide
sal added a comment -

Changing drop_font_tag option does fix problem but not a good solution.

Adding in clean option does strip font tag and replaces with span... however instead of keeping inline style it replaces it with a class declaration (class="c1") which is a non-existent class within the external css file.

Is there not a way to change the html editor to use span tags instead of font tags when changing either font color or font background color?

Show
sal added a comment - Changing drop_font_tag option does fix problem but not a good solution. Adding in clean option does strip font tag and replaces with span... however instead of keeping inline style it replaces it with a class declaration (class="c1") which is a non-existent class within the external css file. Is there not a way to change the html editor to use span tags instead of font tags when changing either font color or font background color?
Hide
sal added a comment -

oh by the way, I am using 1.9.6

Show
sal added a comment - oh by the way, I am using 1.9.6
Hide
Martin Dougiamas added a comment -

The TInyMCE editor in Moodle 2 fixes this.

Show
Martin Dougiamas added a comment - The TInyMCE editor in Moodle 2 fixes this.

People

Vote (10)
Watch (4)

Dates

  • Created:
    Updated:
    Resolved: