Newsletter Custom Subscription Form - Specific Campaigns Only

Logan Romine asked on October 17, 2016 22:42

When trying to use the Custom Subscription Form Web Part to sign users up for newsletters, it displays all email campaign when allowing the NewsletterName property to display (Want users to select campaigns to sign up but only select campaigns). Is there anyway to limit what campaigns show up for subscribers to subscribe?

Correct Answer

Joshua Adams answered on October 17, 2016 22:51

You can clone the custom subscription form and create your customized webpart. Looks like around line 446 you could attach a where statement to the query.

ds = NewsletterInfoProvider.GetNewslettersForSite(SiteContext.CurrentSiteID).OrderBy("NewsletterDisplayName").Where("Your where clause").Columns("NewsletterDisplayName", "NewsletterName");

1 votesVote for this answer Unmark Correct answer

Recent Answers


Logan Romine answered on October 18, 2016 15:38

Thanks Joshua, that worked for me!

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.