-
Notifications
You must be signed in to change notification settings - Fork 382
Automatically convert head[profile] to head > link[rel=profile] #4131
Description
Feature description
When doing an analysis of themes on WordPress, I got a DISALLOWED_ATTR validation error for the profile attribute on the head element, such as code in :
<head profile="http://gmpg.org/xfn/11">The profile attribute on the head element is part of HTML4 but not HTML5.
The W3 validator provides this advice:
According to this SO answer, the right way to represent this in HTML5 is:
<head>
<!-- … -->
<link rel="profile" href="http://gmpg.org/xfn/11">This should perhaps be done as part of the normalization done in the Document class (appending the link element to the end of the head). It could also be done in a separate sanitizer, though that may be overkill. Since the Document class is normalizing to HTML5, I think it makes sense to let the class handle the profile transformation.
Do not alter or remove anything below. The following sections will be managed by moderators only.
