I would like to know how to set description and meta keywords for the front page. I use the Meta tags module for articles, but it is not working for the front page.
I use Panel as my front page.
My website is http://www.techiestuffs.com, and runs on Drupal 7.
if you see the HTML source of the front page, it only contains the following HTML:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<link rel="shortcut icon" href="http://www.techiestuffs.com/sites/default/files/favicon.png" type="image/png"/>
<meta name="Generator" content="Drupal 7 (http://drupal.org)"/>
<title>TechieStuffs | Stuffs for Geeks</title>
I had tried adding these functions in template.php:
function yourtheme_page_alter($page) {
$meta_description = array(
'#type' => 'html_tag',
'#tag' => 'meta',
'#attributes' => array(
'name' => 'description',
'content' => 'Description about the site'
));
$meta_keywords = array(
'#type' => 'html_tag',
'#tag' => 'meta',
'#attributes' => array(
'name' => 'keywords',
'content' => 'Some Keywords about the site'
));
drupal_add_html_head($meta_description, 'meta_description');
drupal_add_html_head($meta_keywords, 'meta_keywords');
}
But this function does not seems to work as you can see in my websites source code.
Does anyone know how to work out this?
