Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I could not find support for meta name="author" in the module, is this something that's missing or am I overlooking something? http://www.metatags.org/meta_name_author
Only could find the Google+ author page metatab but that is different.
Comment | File | Size | Author |
---|---|---|---|
#16 | metatag-n2403349-16.patch | 3.47 KB | DamienMcKenna |
| |||
#16 | metatag-n2403349-16.interdiff.txt | 2.35 KB | DamienMcKenna |
#12 | metatag-n2403349-12.patch | 1.13 KB | DamienMcKenna |
Comments
Comment #1
pvhee CreditAttribution: pvhee commentedComment #2
DamienMcKennaOh my. Well fudge, the current tag's internal name is "author", so this would have to be e.g. "name_author". This would also then have to extend the API to allow an optional e.g. 'name_override' attribute in hook_metatag_info() that would replace the value in the HTML.
Comment #3
DamienMcKennaComment #4
pvhee CreditAttribution: pvhee commentedAs a temporary fast fix, I implemented the hook_metatag_info_alter hook to alter the author tag behavior. Of course this removes the author link, so it's probably not recommended to do this without understanding the impact of it, but it's definitely faster than patching metatag and the API
Comment #5
DamienMcKennaStandardized the issue title.
Comment #6
sitiveni CreditAttribution: sitiveni commentedAdding the "Author" tag (or any other custom metatag) in Drupal 8 is done by creating files for schema and plugin.
Schema (my_module/config/schema/my_module.metatag_tag_schema.yml):
Plugin (my_module/src/Plugin/metatag/Tag/Author.php):
Comment #7
DamienMcKennaComment #8
DamienMcKennaComment #9
DamienMcKennaNeed to do some more research on where this is actually used, and make sure there's a corresponding D8 issue too.
Comment #10
thejimbirch CreditAttribution: thejimbirch at Kanopi Studios commentedThe
author
meta tag is a part of the HTML Living Standard specification:https://html.spec.whatwg.org/multipage/semantics.html#standard-metadata-...
And in the W3C HTML 5.2 HTML 5.2 specification recommendation:
https://www.w3.org/TR/html52/document-metadata.html#author
Besides the page the original poster included, I can't find anyone that says they consume the author tag.
This article from Moz, originally from 2017, refreshed in 2019 states:
The link to "Google saying so" is now broken.
I'd lean towards adding the tag and add the D8 issue to add the tag since it is in the official HTML specifications.
Comment #11
DamienMcKennaComment #12
DamienMcKennaOk, well here's a first pass.
Comment #13
DamienMcKennaComment #15
DamienMcKennaComment #16
DamienMcKennaAh! It fails because it conflict with the rel="author" meta tag from Google+. So let's just dump the G+ one and take over the namespace.
Comment #18
DamienMcKennaCommitted.
Comment #19
DamienMcKenna