README.txt 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248
  1. DESCRIPTION
  2. -----------
  3. Simplenews publishes and sends newsletters to lists of subscribers. Both
  4. anonymous and authenticated users can opt-in to different mailing lists.
  5. HTML email can be sent by adding Mime mail module.
  6. REQUIREMENTS
  7. ------------
  8. * For large mailing lists, cron is required.
  9. * HTML-format newsletters and/or newsletters with file attachments require the
  10. mime mail or HMTL mail module.
  11. * When sending newsletters on regular cron (cron.php), it is important that
  12. the base url (settings.php, variable $base_url) is set correctly or links
  13. inside the newsletter will not work. See the Tips (13.) below.
  14. * Additionally when using Drush to start cron, it is important to use the
  15. argument --uri=http://www.example.com
  16. INSTALLATION
  17. ------------
  18. 1. CREATE DIRECTORY
  19. Create a new directory "simplenews" in the sites/all/modules directory and
  20. place the entire contents of this simplenews folder in it.
  21. 2. ENABLE THE MODULE
  22. Enable the module on the Modules admin page.
  23. 3. ACCESS PERMISSION
  24. Grant the access at the Access control page:
  25. People > Permissions.
  26. 4. CONFIGURE SIMPLENEWS
  27. Configure Simplenews on the Simplenews admin pages:
  28. Configuration > Simplenews.
  29. Enable new content types to use as newsletter:
  30. Structure > edit content type > Publishing options
  31. Add and configure newsletter categories:
  32. Structure > Web Services > Newsletters > Add newsletter category
  33. Structure > Web Services > Newsletters > edit newsletter category
  34. 5. ENABLE SIMPLENEWS BLOCK
  35. With the Simplenews block users can subscribe to a newsletter.
  36. Enable a Simplenews block per Newsletter category:
  37. Structure > Newsletters > edit newsletter category
  38. 6. CONFIGURE SIMPLENEWS BLOCK
  39. Configure the Simplenews block on the Block configuration page. You reach
  40. this page from Block admin page (Structure > Blocks).
  41. Click the 'Configure' link of the appropriate simplenews block.
  42. Permission "subscribe to newsletters" is required to view the subscription
  43. form in the simplenews block or to view the link to the subscription form.
  44. 7. SIMPLENEWS BLOCK THEMING
  45. More control over the content of simplenews blocks can be achieved using
  46. the block theming. Theme your simplenews block by copying
  47. simplenews-block.tpl.php into your theme directory and edit the content.
  48. The file is self documented listing all available variables.
  49. The newsletter block can be themed generally and per newsletter:
  50. simplenews-block.tpl.php (for all newsletters)
  51. simplenews-block.tpl--[tid].php (for newsletter series tid)
  52. 8. MULTILINGUAL SUPPORT
  53. Simplenews supports multilingual newsletters for node translation,
  54. multilingual taxonomy and url path prefixes.
  55. When translated newsletter issues are available subscribers receive the
  56. newsletter in their preferred language (according to account setting).
  57. Translation module is required for newsletter translation.
  58. Multilingual taxonomy of 'Localized terms' and 'per language terms' is
  59. supported. 'per language vocabulary' is not supported.
  60. I18n-taxonomy module is required.
  61. Use 'Localized terms' for a multilingual newsletter. Taxonomy terms are
  62. translated and translated newsletters are each tagged with the same
  63. (translated) term. Subscribers receive the newsletter in the preferred
  64. language set in their account settings or in the site default language.
  65. Use 'per language terms' for mailing lists each with a different language.
  66. Newsletters of different language each have their own tag and own list of
  67. subscribers.
  68. Path prefixes are added to footer message according to the subscribers
  69. preferred language.
  70. The preferred language of anonymous users is set based on the interface
  71. language of the page they visit for subscription. Anonymous users can NOT
  72. change their preferred language. Users with an account on the site will be
  73. subscribed with the preferred language as set in their account settings.
  74. The confirmation mails can be translated by enableding the Simplenews
  75. variables at:
  76. Home > Administration > Configuration > Regional and language > Multilingual settings > Variables
  77. Afterwards, the mail subject and body can be entered for every enabled
  78. language.
  79. 9. NEWSLETTER THEMING
  80. You can customize the theming of newsletters. Copy any of the *.tpl.php
  81. files from the simplenews module directory to your theme directory. Both
  82. general and by-newsletter theming can be performed.
  83. Theme newsletter body:
  84. simplenews-newsletter-body.tpl.php (for all newsletters)
  85. simplenews-newsletter-body--[tid].tpl.php
  86. simplenews-newsletter-body--[view mode].tpl.php
  87. simplenews-newsletter-body--[tid]--[view mode].tpl.php
  88. [tid]: Machine readable name of the newsletter category
  89. [view mode]: 'email-plain', 'email-html', 'email-textalt'
  90. Example:
  91. simplenews-newsletter-body--1--email-plain.tpl.php
  92. Theme newsletter footer:
  93. simplenews-newsletter-footer.tpl.php (for all newsletters)
  94. simplenews-newsletter-footer--[tid].tpl.php
  95. simplenews-newsletter-footer--[view mode].tpl.php
  96. simplenews-newsletter-footer--[tid]--[view mode].tpl.php
  97. [tid]: Machine readable name of the newsletter category
  98. [view mode]: 'email-plain', 'email-html', 'email-textalt'
  99. Example:
  100. simplenews-newsletter-footer--1--email-plain.tpl.php
  101. The template files are self documented listing all available variables.
  102. Depending on how the mails are sent (e.g. how cron is triggered), either the
  103. default or the admin theme might be used, if one has been configured.
  104. To prevent this, Simplenews supports the mail theme setting from the
  105. mailsystem module (http://drupal.org/project/mailsystem). Install it, choose
  106. the mail theme and the newsletter templates from that theme will be used no
  107. matter which other themes are enabled.
  108. Using the fields Display settings each field of a simplenews newsletter can
  109. be displayed or hidden in 'plain text', 'HTML' and 'HTML text alternative'
  110. format. You find these settings at:
  111. Structure > Content types > Manage display
  112. Enable the view modes you want to configure and configure their display.
  113. 10. SEND MAILING LISTS
  114. Cron is required to send large mailing lists.
  115. If you have a medium or large size mailing list (i.e. more than 500
  116. subscribers) always use cron to send the newsletters.
  117. To use cron:
  118. * Check the 'Use cron to send newsletters' checkbox.
  119. * Set the 'Cron throttle' to the number of newsletters send per cron run.
  120. Too high values may lead to mail server overload or you may hit hosting
  121. restrictions. Contact your host.
  122. Don't use cron:
  123. * Uncheck the 'Use cron to send newsletters' checkbox.
  124. All newsletters will be sent immediately when saving the node. If not
  125. all emails can be sent within the available php execution time, the
  126. remainder will be sent by cron. Therefore ALWAYS enable cron.
  127. These settings are found on the Newsletter Settings page under
  128. 'Send mail' options at:
  129. Administer > Configuration > Web Services > Newsletters > Settings > Send mail.
  130. 11. (UN)SUBSCRIBE CONFIRMATION
  131. By default the unsubscribe link will direct the user to a confirmation page.
  132. Upon confirmation the user is directed to the home page, where a message
  133. will be displayed. On the Simplenews subscription admin page you can
  134. specify an alternative destination page.
  135. Structure > Configuration > Web Services > Newsletters > edit newsletter category > Subscription settings
  136. To skip the confirmation page you can add parameters to the subscription URL.
  137. Example: [simplenews-subscribe-url]/ok
  138. When an alternative destination page has been defined the extra parameters
  139. will be added to the destination URL.
  140. Example: [simplenews-subscriber:subscribe-url]/ok
  141. Destination: node/123
  142. Destination URL: node/123/ok
  143. 12. SINGLE OR DOUBLE OPT-IN AND OPT-OUT
  144. Every newsletter can be set to be double opt-in/out (default), single
  145. opt-in/out, or hidden.
  146. Double: A confirmation email is sent to confirm the (un)subscribe action.
  147. No confirmation is sent when a user is (un)subscribed by the
  148. administrator or when the user subscribes when creating an account.
  149. Single: No confirmation email is sent. (un)subscribe is immediately.
  150. Hidden: The newsletter is not listed in newsletter lists. Use this for
  151. mandatory newsletters. Only administrators or modules can add a user to this
  152. mailing list.
  153. Note that single opt-in/out or hidden (forced) subscription is in some
  154. countries forbidden by law.
  155. SECURITY NOTICE: a newsletter set to be single opt-in or opt-out is
  156. vulnerable to Cross Site Request Forgeries. Email addresses may be
  157. (un)subscribed without a notice. Do not use this setting in uncontrolled
  158. environments (like the internet!).
  159. 13. TIPS
  160. A subscription page is available at: /newsletter/subscriptions
  161. The Elysia Cron module (http://drupal.org/project/elysia_cron) can be used
  162. to start the simplenews cron hook more often than others, so that newsletter
  163. are sent faster without decreasing site performance due to long-running cron
  164. hooks.
  165. If your unsubscribe URL looks like:
  166. http://newsletter/confirm/remove/8acd182182615t632
  167. instead of:
  168. http://www.example.com/newsletter/confirm/remove/8acd182182615t632
  169. You should change the base URL in the settings.php file from
  170. # $base_url = 'http://www.example.com'; // NO trailing slash!
  171. to
  172. $base_url = 'http://www.example.com'; // NO trailing slash!
  173. RELATED MODULES
  174. ------------
  175. * Elysia Cron
  176. Allows fine grained control over cron tasks.
  177. http://http://drupal.org/project/elysia_cron
  178. * Mailsystem
  179. Extends drupal core mailystem wirh Administrative UI and Developers API.
  180. http://drupal.org/project/mailsystem
  181. * Maillog
  182. Captures outgoing mails, helps users debugging simplenews.
  183. http://drupal.org/project/maillog
  184. DOCUMENTATION
  185. -------------
  186. More help can be found on the help pages: example.com/admin/help/simplenews
  187. and in the drupal.org handbook: http://drupal.org/node/197057