Skip to content

Accents in URIs cause incorrect warning "escaping malformed URI reference" #378

@a3nm

Description

@a3nm

Consider the following document (in UTF-8):

<!DOCTYPE html>
<html dir="ltr" xml:lang="en" lang="en">
<head>
  <title>a</title>
  <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
</head>
<body>
  <p><a href="http://example.com/é">foo</a></p>
</body>
</html>

When running /usr/local/bin/tidy -utf8 -errors -quiet on this document, I get the following warning:

line 8 column 6 - Warning: <a> escaping malformed URI reference

The warning only shows up when the href contains an accented character. This seems bogus to me, I don't think non-ASCII characters in href are disallowed. Further, validator.w3.org accepts the document. I think the warning shouldn't be emitted.

This may be related to #352, but maybe not.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions