You are here

function notifications_anonymous_subscribe_links in Notifications 6.4

Build subscription options as an array of links

These links can be added as node link elements or rendered some other way

Parameters

$subscription_types: Array of subscription objects, either actual subscriptions or subscription templates

$prefix: Prefix to use for the link indexes

File

notifications_anonymous/notifications_anonymous.module, line 183
Notifications for anonymous users

Code

function notifications_anonymous_subscribe_links($type, $object) {
  global $user;
  notifications_include('object.inc');

  // For subscribe, we need confirmation form always, as we need destination address
  $subscribe = array();
  $unsubscribe = array(
    'type' => 'subscription',
    'signed' => TRUE,
  );
  return notifications_object_subscribe_links($type, $object, $user, $subscribe, $unsubscribe);
}