Closed (fixed)
Project:
Nodewords: D6 Meta Tags
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
17 Mar 2010 at 10:51 UTC
Updated:
3 Jan 2014 at 01:08 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
hanoiiAre you using this module or only nodewords? This is nodewords_nodetye (Nodewords Meta Tags). From your description you only mention nodewords, so I am moving the issue to that module, if you do use this module as well. Please disable and try this issue out. If you still experience the problem, then it's nodewords, if you don't then it may be this module and I can took a look at it.
Also if it's nodewords, inform your version number, I am changing it to the latest.
Comment #2
Anonymous (not verified) commentedIt's done by Drupal core code; check the source on any pages on Drupal.org, and you will notice the same meta tag is printed twice (Drupal.org does not use Nodewords).
Comment #3
gjansen commentedI'm having the same problem.
I do use the nodewords module.
Any suggestions how I can prevent this duplicate META-Tag?
Comment #4
Anonymous (not verified) commentedSee the previous comment; you cannot fix it because it is done by Drupal core code.
Comment #5
brunodboConfirming that this meta tag appears twice when using nodewords. This happens in nodewords.module, on line 542.
Attached patch removes the charset meta tag added by nodewords (since it's already added by Drupal core).
Comment #6
brunodboAnd here's the patch ..
Comment #7
avpadernoThe code in Nodewords has been already changed.
That is not correct; the content type meta tags appears twice because it is added from Drupal.
See the source of this page, and you will see it twice, even though Drupal.org doesn't use Nodewords.
Comment #8
brunodboI'm not sure if I understand: are you saying Drupal core adds the Content-Type meta tag twice? When I remove that code from nodewords.module (v6.x-1.11, the current stable release), the Content-Type meta tag appears only once in my source.
Comment #9
Anonymous (not verified) commentedYes, it does. There is also a report in the Drupal project queue (#451304: Drupal outputs two meta content-type tags). Then, it's evident the meta tag content-type is added from Drupal from the following code:
I think that seeing the content type meta tag twice in a site that doesn't use Nodewords is a clear demonstration that is not an issue related with Nodewords.
Comment #10
jfine commentedI just noticed this issue. This is not a duplicate of #451304.
Line 542-544 in nodewords.module duplicates the content type.
When I remove the content-type section of this string the duplicate goes away. Additionally when I disable the nodewords module the duplicate goes away. What was the purpose behind nodewords adding a content-type?
Additionally, it doesn't look like drupal_set_html_head() is being used properly by nodewords. Other modules trying to hook into head via the API effectively drupal_set_html_head() and drupal_get_html_head() will effectively remove the tags added by nodewords.
Comment #11
damienmckennaComment #12
dave reidThe current code is no longer in 6.x-1.x and looks fixed to me. I can't reproduce the duplicate Content-Type tag with the latest code.
Comment #14
chaloalvarezj commentedI had this bug on the 6.x-1.11 version, and the patch in #6 Posted by brunodbo solved it. However, after updating to the latest 6.x-1.x-dev version of December 2, 2010, the bug persist! and the patch does not apply anymore.
Edit: Just uninstalled nodewords altogether... and the double meta: http-equiv="Content-Type" is still there. So it appears to be Drupal bug after all.
Comment #15
dave reidIt is not a nodewords issue. It does not add any content-type meta tags itself. What is really responsible is this Drupal core issue: #451304: Drupal outputs two meta content-type tags.
Comment #16
damienmckennaNeeds to be re-rolled against the latest 6.x-1.x codebase.
Comment #17
damienmckennaPatch attached.
Comment #18
dave reidThis has been re-applied.