Handles subscription for the current user through personalization

Namespace:  EPiServer.Personalization
Assembly:  EPiServer (in EPiServer.dll) Version: 5.2.375.236

Syntax

C#
public class Subscription

Remarks

Subscription stores the state as SubscriptionInfo in the personalized EPiServerProfile object

This class uses internally the SubscriptionInfo class that support reading subscription information from a arbitrary user but passes in the currently online cached user.

Examples

Adds a subscription for a user
CopyC#
if (Subscription.IsSubscribingTo(CurrentPageLink))
    Response.Write("User is already subscribing");
else
{
    Subscription.SubscribeTo(CurrentPageLink);
    Response.Write("Subscription addedd");
}

Inheritance Hierarchy

System..::.Object
  EPiServer.Personalization..::.Subscription

See Also