Opened 14 years ago
Closed 9 years ago
#14664 closed enhancement (fixed)
add <link rel="profile" ... /> to wp_head()
Reported by: | ramiy | Owned by: | |
---|---|---|---|
Milestone: | 3.9 | Priority: | normal |
Severity: | normal | Version: | 3.0.1 |
Component: | Themes | Keywords: | has-patch |
Focuses: | Cc: |
Description
Old themes use rel="profile" in <head>, twentyten use it in <link>.
Both ways are ok (http://microformats.org/wiki/rel-profile), and i think <link> is better (like in twentyten).
Currently, theme authors add the profile rel manually. They usualy use XFN 1.1 profile (http://gmpg.org/xfn/11). To change the profile users need to change the template files. This is problematic.
I think we need to add a profile_rel_link function to wp core and add it to wp_head(). This way, when we want to change the profile, we will use filters.
See the attacment.
Attachments (1)
Change History (12)
#6
@
14 years ago
IMHO this isn't about OLD VS 2010 theme. It's basically HTML4 VS HTML5.
HTML4 introduce profile attribute from HEAD. Then HTML5 drops profile attribute from HEAD and then it's suggested to add rel="profile" to LINK.
Perhaps not to be added to default filters but as add_theme_support('profile_rel_link') or something similar to avoid multiple profile defined.
Since twentyten is tagged with microformats this is currently the correct profile URI: <link rel="profile" href="http://microformats.org/profile/specs http://microformats.org/profile/hatom" />
. And for "OLD" theme: <head profile="http://microformats.org/profile/specs http://microformats.org/profile/hatom">
#7
@
14 years ago
add_theme_support('profiles') registers major wordpress feature like custom-header, custom-background, post-thumbnails, menus and more.
add_action('wp_head','profile_rel_link',1) addes simple <link> element to <head>.
The use of theme support sounds good BUT in this case i prefer to use a simple head action. "rel-profiles" is not a wordpress feature, it a simple head element indicates that microformat's vocabulary is formally defined in the document.
#9
@
14 years ago
- Milestone changed from Awaiting Review to Future Release
I'm considering a way for a theme to specifically opt-in to HTML5 goodies such as this.
#10
@
14 years ago
According to Theme Review:
"Correct XFN profile link in <head> tag: <head profile="http://gmpg.org/xfn/11"> (Exception: Wholly HTML 5 themes must not have the profile, as HTML 5 does not support it.)"
Further reading:
To change the profile to XEN 1.0, use something like: