simplenews_scheduler.api.php 764 B

1234567891011121314151617181920212223
  1. <?php
  2. /**
  3. * @file
  4. * Hooks provided by the Simplenews scheduler module.
  5. */
  6. /**
  7. * Alter the node object that was cloned from the template node before it gets saved.
  8. *
  9. * The node is passed as node object and therefore passed by reference. This hook
  10. * is for example usefull if you have fields in the template node that contain
  11. * information about data that should get rendered dynamically into the edition
  12. * node depenedent on the current schedule date.
  13. *
  14. * @param $edition_node
  15. * The cloned node object based on the scheduler node.
  16. * @param $scheduler_node
  17. * The original scheduler node object.
  18. */
  19. function hook_simplenews_scheduler_edition_node_alter($edition_node, $scheduler_node) {
  20. $node->title = 'Your newsletter from ' . REQUEST_TIME;
  21. }