Page MenuHomePhabricator

Add meta Content-Style-Type tag
Closed, ResolvedPublic

Description

Author: gurkenpapst

Description:
According to http://www.w3.org/TR/html4/present/styles.html#default-style you need to define the style sheet language to have correct markup when using style attributes.

Documents that include elements that set the style attribute but which don't define a default style sheet language are incorrect.

MediaWiki uses elements with style attributes but is lacking this information (at least on the pages I checked).

While http://validator.w3.org/ does not detect this as an error, a more strict validator like http://www.validome.org/ does: http://www.validome.org/validate/?uri=http://www.mediawiki.org/wiki/MediaWiki

Suggested fix: <meta http-equiv="Content-Style-Type" content="text/css" /> should be added into the head element of every page.

While I have not found any occurence during a quick search, there might also be a quite similar problem in the definition of the default script language:
http://www.w3.org/TR/html4/interact/scripts.html#h-18.2.2

Documents that do not specify default scripting language information and that contain elements that specify an intrinsic event script are incorrect.


Version: unspecified
Severity: trivial
URL: http://www.mediawiki.org/wiki/MediaWiki

Details

Reference
bz15835

Related Objects

StatusSubtypeAssignedTask
ResolvedNone
ResolvedNone

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:22 PM
bzimport set Reference to bz15835.
bzimport added a subscriber: Unknown Object (MLST).

gurkenpapst wrote:

Oops, summary should of course be: [...] definition of Content-*Style*-Type

IIRC there's similar bug somewhere around

marco wrote:

Patch at http://pastebin.com/m773e89f1, searching for someone with commit access