simplenews-newsletter-body.tpl.php

Tracking 6.x-2.x branch
  1. drupal
    1. 6 contributions/simplenews/theme/simplenews-newsletter-body.tpl.php

Default theme implementation to format the simplenews newsletter body.

Copy this file in your theme directory to create a custom themed body. Rename it to simplenews-newsletter-body--<tid>.tpl.php to override it for a newsletter using the newsletter term's id.

Available variables:

  • $node: Newsletter node object
  • $body: Newsletter body (formatted as plain text or HTML)
  • $title: Node title
  • $language: Language object

Available tokens:

  • [simplenews-unsubscribe-url]: unsubscribe url to be used as link

for more tokens: see simplenews_token_list()

Note that unsubscribe links are broken in case of test send to a non-subscriber.

See also

template_preprocess_simplenews_newsletter_body()

File

View source
  1. <?php
  2. /**
  3. * @file
  4. * Default theme implementation to format the simplenews newsletter body.
  5. *
  6. * Copy this file in your theme directory to create a custom themed body.
  7. * Rename it to simplenews-newsletter-body--<tid>.tpl.php to override it for a
  8. * newsletter using the newsletter term's id.
  9. *
  10. * Available variables:
  11. * - $node: Newsletter node object
  12. * - $body: Newsletter body (formatted as plain text or HTML)
  13. * - $title: Node title
  14. * - $language: Language object
  15. *
  16. * Available tokens:
  17. * - [simplenews-unsubscribe-url]: unsubscribe url to be used as link
  18. * for more tokens: see simplenews_token_list()
  19. *
  20. * Note that unsubscribe links are broken in case of test send to a non-subscriber.
  21. *
  22. * @see template_preprocess_simplenews_newsletter_body()
  23. */
  24. ?>
  25. <h2><?php print $title; ?></h2>
  26. <?php print $body; ?>