Skip to content

XHTML5 wrongly recognized as XHTML 1.0 Transitional #657

Open
@dechamps

Description

@dechamps

On current HEAD (f0438bd):

$ tidy <<EOF
<?xml version="1.0" ?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"><head><title></title></head>
<body>
<img src="foo.jpg" alt="Foo" />
<br />
</body></html>
EOF

Reports:

Info: Document content looks like XHTML 1.0 Transitional

Even though the document is quite obviously XHTML5, with the XML preamble combined with <!DOCTYPE html> and the xmlns attribute being dead giveaways.

Weirdly enough, the document is correctly recognized as XHTML5 if the following is added:

<meta charset="utf-8" />

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions