Try our conversational search powered by Generative AI!

Subscribe without login



Is there anyway of using the episerver subscription module without the user having to log in. I was considering users being able to add there email address to a subscription table but my problem is getting the pages that have been added or changed in order to send the notification to the email addresses specified.


Feb 25, 2010 17:43

Yes, if you enable for anonymous users in your web.config file.


Feb 25, 2010 18:33

I haven't seen that in work, and have made myself some code that automaticly creates users and add them to a subscrtion. Mail me if you want the code at anders.hattestad(at)

Feb 25, 2010 21:57

Not getting this to work.

Have set the subscription page to allow anonymous users and and changed in IIS to allow all users and all anonymous users.
Is there a step-by-step instruction to not get the login page mailed, but the actual content?! An impersonation of some kind?

The site is an intranet with MultiplexingMembershipProvider with ADProvider and EPiserverMembershipProvider.

Nov 08, 2012 17:26

Does the subscribers get emails but the links in the subscription mail shows the login window?

Edited, Nov 08, 2012 20:45

Hi Per. Correct!

Emails har sent but the mail shows a login page instead of the intended content. I guess the scheduler doesnt have sufficent/wrong user rights.

Nov 09, 2012 8:21

If you check the actual links in the email do they point to an actual page or the /util/login.aspx?

When the sceduling job processes the subscription it creates an Iprincipal of the current subscriber and gets all the roles for that user.

An accesscheck is then made on every possible change that should be sent out. So if you get mails sent they should be the actual links to the page.

If you then get the login page following the links in the subscription mail do the pages have Everyone set for read access?

Nov 09, 2012 8:56

No links in the email, just showing a login form. 

Im not able to find the scheduler that process the page.

The subscription page in EPi is set to allow Everyone and even Anonymous read access.


Nov 09, 2012 9:37

The subscriptionjob takes the profile.Username and creates a Iprincipal object that is used to check acess rights.

So when creating the profile for the subscriber (in your subscription page) the must be the username used when logging in.

If not all accesschecks will fail in the subscription job.

When the subscriptinjob is run it goes through all profiles in your database.

For each profile it gets all subscribed pages.

For each of the subscribed pages it tries to get all changed pages below (and here the access check is performed). So it's not enough for the user to be able to subscribe to pages. If they don't have access to the pages below they will not get any links in the mail.

If the current subscriber doesn't have read access no subscription link for the email will be created.

The subscription job is a scheduled plugin in the EPiServer.Personalization namespace. I have a very custom subscription so I have modifed both the subsription job and the handler that creates the actual mail.

Nov 09, 2012 11:07

Jonas: did you get it to work?

Nov 15, 2012 10:50

No, not finding this at all.
Must a override be done to get this work?

Lacking some documentation about this...

Nov 16, 2012 16:19

The subscription functionality is located in EPiServer.dll in the EPiServer.Personalization namespace.

If you wan't to modify that stuff you need do your own version. If you don't have reflector you need to get it. Then you can check how EPiServers implementation is done.


Nov 19, 2012 10:39

Ok debugged some now.

It gets the story from url: /Templates/Emails/SubscriptionUpdate.aspx?id=100&epslanguage=sv&story=37
When I navigate to the address I see it of course. 

only here it breaks

HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url);
            request.Timeout = 10000;
            HttpWebResponse response = (HttpWebResponse)request.GetResponse();// << breaks here
            StreamReader responseStream = new StreamReader(response.GetResponseStream(), Encoding.UTF8);
            string html = responseStream.ReadToEnd();

  a basepage:  

protected override void OnInit(EventArgs e)
            if (CurrentUser == null)  //<< CurrentUser is null
                throw new AccessDeniedException();

            if (Header != null)
                Header.Title = GetDisplayName(CurrentPage);



So on the request part, how do i impersonate user in code?  


Nov 23, 2012 10:08
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.