Meta tags not showing on Drupal front page

If you are using the Drupal Metatag module it might happen, that the meta tags are not shown on the front page despite the fact that you defined them with "Global: front page". And this happens while they are shown on all the other pages.

One very typical reason is, that your theme has a specific configuration for the front page, that doesn't print the content section ($page['content']). This occurs for example with themes from More than themes if the "Drupal frontpage content" option is disabled. Another reason might be that the theme has a specific php file for the front page (Example: page--front.tpl.php) that doesn't print the content section.

To fix this you just add the following lines to the page.tpl.php

<?php if (drupal_is_front_page()): ?>
<?php print render($page['content']['metatags']); ?>
<?php endif; ?>

or these line to the page--front.tpl.php
<?php print render($page['content']['metatags']); ?>


Drupal themes to be compared