I'm attempting to create a tag inside the head of my site using the drupal_add_html_head() function. It is stripping the type attribute from the tag. It should not be doing this. Does anybody know how to prevent this from occurring?
I'm doing this in the theme's template.php file. Here's my code:
function exampletheme_preprocess_html(&$variables) {
$rss = array(
'#type' => 'html_tag',
'#tag' => 'link',
'#attributes' => array(
'rel' => 'alternate',
'type' => 'application/rss+xml',
'href' => 'http://feeds.feedburner.com/examplefeed',
'title' => 'RSS Feed'
)
);
drupal_add_html_head($rss, 'rss');
}
This results in:
<link rel="alternate" href="http://feeds.feedburner.com/examplefeed" title="RSS Feed" />
I get the same results if I use the drupal_add_html_head_link() function. If I misspell the word 'type' then the attribute shows up. But I don't see anything in the functions that would be stripping 'type' from the html attributes.