You are here

function signup_get_email_addresses in Signup 5.2

Retrieve a list of all users who have signed up for a node.

Parameters

$nid:

Return value

An array of objects containing signup data

2 calls to signup_get_email_addresses()
signup_broadcast_form in ./signup.module
Form builder for the signup broadcast form.
signup_broadcast_form_submit in ./signup.module
Send an email message to all those signed up to a node.

File

./signup.module, line 2700
The Signup module (http://drupal.org/project/signup) manages replies to nodes. In particular, it's good for event management. Signup supports sending reminder emails and automatically closing signups for nodes with a start time, via the Event…

Code

function signup_get_email_addresses($nid) {
  $signup_data = array();
  $signups = db_query("SELECT u.uid, u.name, u.mail, s_l.anon_mail, s_l.form_data FROM {signup_log} s_l INNER JOIN {users} u ON u.uid = s_l.uid WHERE s_l.nid = %d", $nid);
  while ($signup_entry = db_fetch_object($signups)) {
    $signup_data[] = $signup_entry;
  }
  return $signup_data;
}