Closed RichardLitt closed 1 year ago
@RichardLitt, the enforce_https
option can be used to control this.
For the command line (htmlproofer --help
):
--[no-]enforce-https Fails a link if it's not marked as `https` (default: `true`).
I think that's different than failing of the link doesn't have an HTTPS equivalent. Right now, the flag itself is an error, because the link is correct.
@RichardLitt let me try to clarify the behavior.
The way html-proofer behaves w.r.t enforce_https
is just detecting a failure for any http:// link, regardless of whether it or its https:// counterpart exists (is accessible).
If you do not want html-proofer to detect such failures, and instead just do the check of whether the link as specified exists, just disable this behavior via --no-enforce-https
.
Linking here an old issue #314 with some discussions around http:// links having https:// alternative, which is not something html-proofer is meant to check.
Got it! Thank you.
As well, if you'd prefer to keep HTTPS checks on for everything, but off for this one link, you could:
data-proofer-ignore
to the element; this will ignore it from all the checksignore_urls
; this will ignore it from all the link checks, eg., if this link is broken, it also wouldn't be reported.
I get the following error:
For that site, there is no HTTPS enabled. Should this be flagged?