You are here

function hook_scheduler_nid_list in Scheduler 7

Same name and namespace in other branches
  1. 8 scheduler.api.php \hook_scheduler_nid_list()

Allow modules to add node ids to the list being processed.

Modules can implement hook_scheduler_nid_list() to add more node ids into the list to be processed in the current cron run. This hook is invoked during cron runs only. It is maintained for backwards compatibility but has been superceded by hook_scheduler_nid_list_alter(), which has more functionality.

Parameters

string $action: Indicates what is being done to the node. The value will be 'publish' or 'unpublish'.

Return value

array Array of node ids to add to the existing list of nodes to be processed.

1 invocation of hook_scheduler_nid_list()
_scheduler_scheduler_nid_list in ./scheduler.cron.inc
Gather node IDs for all nodes that need to be $action'ed.

File

./scheduler.api.php, line 64
API documentation for the Scheduler module.

Code

function hook_scheduler_nid_list($action) {
  $nids = array();

  // Do some processing to add new node ids.
  return $nids;
}