You are here

function newsletter_subscriber_load in Newsletter 7

Same name and namespace in other branches
  1. 7.2 modules/subscriber/newsletter_subscriber.module \newsletter_subscriber_load()

Loads up the requested subscriber.

7 calls to newsletter_subscriber_load()
NewsletterBasic::sendBasic in includes/newsletter.basic.inc
Sends email to a subscriber using a basic template (confirmation/welcome/unsubscribe emails).
NewsletterSubscriberController::delete in includes/newsletter.subscriber.controller.inc
newsletter_create_send_form_page_two_submit in includes/newsletter.admin.inc
newsletter_manage_subscriptions_form in includes/newsletter.pages.inc
newsletter_subscribers_by_list in ./newsletter.module
Get the subscribers of a newsletter list.

... See full list

File

./newsletter.module, line 1001
Defines menu items for newsletter administration, permissions and basic drupal hooks.

Code

function newsletter_subscriber_load($nsids = FALSE, $conditions = array(), $reset = FALSE) {
  if (is_numeric($nsids)) {
    $id = $nsids;
    $nsids = !empty($nsids) ? array(
      $nsids,
    ) : array();
  }
  $subscribers = entity_load('newsletter_subscriber', $nsids, $conditions, $reset);
  return isset($id) ? $subscribers[$id] : $subscribers;
}