Displaying a field in a Drupal 7 template

To display the content field of the node in the template, you need to output the following code in the node--{node-type}.tpl.php file

<?php print render($content['field_maps']); ?>

where 'field_maps' is the machine name of the content field.

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.
The comment language code.