NOTE: The current preferred location for bug reports is the GitHub issue tracker.
Bug 943 - Bad value when validating mailto href tag - Illegal character in query component
Bad value when validating mailto href tag - Illegal character in query component
Status: RESOLVED INTENTIONAL
Product: Validator.nu
Classification: Unclassified
Component: HTML parser
HEAD
All All
: P2 normal
Assigned To: Nobody
( various )
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-09-20 17:12 CEST by Christopher Juckins
Modified: 2012-10-01 21:41 CEST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christopher Juckins 2012-09-20 17:12:58 CEST
I am using http://validator.nu/ to check the following web page:

http://origin.opc.ncep.noaa.gov/opc_mobile_cj.php

I get this error message:

Bad value mailto:ncep.list.opc_web@noaa.gov?subject=[OPC%20mobile%20feedback] for attribute href on element a: Illegal character in query component.

The validator fails on this exact HTML syntax:

Feedback: <a href="mailto:ncep.list.opc_web@noaa.gov?subject=[OPC%20mobile%20feedback]">ncep.list.opc_web@noaa.gov</a><br>

However, if I remove the bracket characters [ and ] in that syntax so that the HTML is now the following:

Feedback: <a href="mailto:ncep.list.opc_web@noaa.gov?subject=OPC%20mobile%20feedback">ncep.list.opc_web@noaa.gov</a><br>

then the validator does not report errors.

It appears that a special character such as a bracket or a parenthesis before the quote in the closing a href tag is causing the validator to report an incorrect error.

I believe the existence of the bracket characters should not cause the validator to fail.

Thank you for making this tool available.

Regards,
Christopher Juckins
Comment 1 Henri Sivonen 2012-09-21 14:35:53 CEST
The IRI spec requires [ and ] to be percent-escaped. See the BNF in http://tools.ietf.org/html/rfc3987
Comment 2 Christopher Juckins 2012-10-01 21:41:14 CEST
Thank you for letting me know; I made the change and now it validates.