web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Suggested Answer

Subscription Center page on portal does not prefill information

(0) ShareShare
ReportReport
Posted on by

Hello,

I need a page in my portal where my user can check or uncheck every newsletter we have. I have created a subscription center and a marketing form for this. 

I have integrated the marketing form using the HTML and JS provided on my portal. The form appears well, but I cannot save it. It says "unknown error occurred".

By looking at the error message in my console, I can see that the contact id is unknown.

If I add my portal contact to the subscription list manually via the Marketing app, I see nothing change on the portal. That's why I suspect the prefill is not working and the marketing form actually has no idea what contact am I working with.

If I include a link to the whole subscription center, then this is the exact same problem. The form appears, I can see all our newsletters, but checking or unchecking any newsletters results in the error message "unknown error occurred".

What can I do to debug this?

I have the same question (0)
  • cloflyMao Profile Picture
    25,210 on at

    Hi Steven,

    You should open subscription center page via the link inside marketing email which is sent to recipient,

    only by doing this, subscription management would work.

    e.g:

    Due to marketing emails are sent in bulk , so in every email, a subscription center link( {{msdyncrm_contentsettings.msdyncrm_subscriptioncenter}} ) is required to be embedded into email content, 

    recipient can choose to refuse to receive any if he/she had not any interest in it by checking "Do not email" option in subscription center page.

    The link contains some query parameters to identify who the current recipient is.

    pastedimage1586483206433v1.png

    Then a retrieving request will be sent to Dynamics Marketing back-end to prefill form fields.

    pastedimage1586483505400v2.png

    pastedimage1586483628156v3.png

    So in other word, the subscription center won't work correctly if you open its URL directly, or click a link sent in a test message.

    To test your subscription center, you should send yourself a subscription-center link in a live email from a live customer journey.

    Please check article below for how to set up a subscription center, you can also find how does SC page work in it:

    https://docs.microsoft.com/en-us/dynamics365/marketing/set-up-subscription-center#test-your-subscription-center

    Regards,

    Clofly

  • Community Member Profile Picture
    on at

    Hello,

    thanks for your reply. So I'm wondering how that the external hosting of a marketing form would ever work if it's not possible to link to that page?

    Thanks for your insights,

  • Suggested answer
    cloflyMao Profile Picture
    25,210 on at

    Hi Steven,

    A subscription center type form can be embedded into external hosting web page by following steps:

    1. Authenticate domain of your own server:

    The second option will enable form prefilling feature on our web page,

    pastedimage1586505305962v1.png

    2. Copy generated script for embedding from "Form page" record in "Form hosting" tab of "Marketing form" record:

    (paste code to custom/external subscription center page)

    pastedimage1586505436567v2.png

    3. Create a new content setting or modify the default, set "Subscription center" field to our own subscription center page.

    pastedimage1586505700240v3.png

    4. Before go live a customer journey, change "Content settings" field to setting which has been applied with custom external page.

    pastedimage1586505829751v5.png

    5. Then Dynamics Marketing will generate a special URL, which contains our own subscription page URl and retrieving data as parameters.(they are encoded data)

    pastedimage1586506022790v6.png

    When we click the link, a new tab will be opened, and href will be converted to our own web page URL automatically, and all fields have been prefilled.

    pastedimage1586506146586v7.png

    Regards,

    Clofly

  • Petit Hibou Profile Picture
    on at

    Adding my 2 cents to the detailed explanation of Clofly :)

    - why you may get an error message and id is unknown - it may be in a situation when cookies are disabled on your web browser

    Update: the browser on a user side - where he fills in the form and opens his subscription center home page

  • Community Member Profile Picture
    on at

    Thank you for the explanation. Will I also have to verify my portal, because I don't have access to the DNS as it runs on a powerappsportals.com?

  • cloflyMao Profile Picture
    25,210 on at

    Hi Steven,

    There is no need to verify portal(and we can't) if you host subscription center on portal.

    Portal is whitelisted automatically.

    Regards,

    Clofly

  • Community Member Profile Picture
    on at

    That is very true. It's also why I asked how to debug this further, as I only got the message "An error has occurred", which wasn't very helpful.

    But thanks for your information, nonetheless. It's helpful.

  • Community Member Profile Picture
    on at

    Thank you for your very detailed explanation, it really helped. Am I right in understanding that I cannot provide a link on my portal directly to the subscription center? That this is something that just cannot be done?

  • Suggested answer
    cloflyMao Profile Picture
    25,210 on at

    Hi Steven,

    We can only submit subscription center form successfully when we open the page via link in delivered email.(All fields have been prefilled.)

    If we open SC directly(all input fields are blank and no input fields will be prefilled in this situation), we will always receive "An error has occurred".

    So you understanding is right: we cannot provide a link on portal directly to the subscription center, it cannot be done.

    Open the subscription center via link in delivered marketing email is the only option,

    please create a simple customer journey (segment -> marketing email) to test subscription center feature.

    Regards,

    Clofly

  • Jonas Velling Profile Picture
    142 on at

    I'm also just adding some knowledge to this:

    We have been testing this on iPhone where the prefilling will not work in most cases, as per default Safari blocks cookies. So if you have been testing the correct way, as described by Clofly, you would probably still experience errors from iPhone/Safari/iOS.

    /Jonas

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

News and Announcements

Season of Giving Solutions is Here!

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Pallavi Phade Profile Picture

Pallavi Phade 101

#2
Tom_Gioielli Profile Picture

Tom_Gioielli 66 Super User 2025 Season 2

#3
TAHER Mehdi Profile Picture

TAHER Mehdi 58

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans