Why this matters
When you off‑load sign‑in to Azure AD B2C, the portal’s native login screen is bypassed. That can make it look as if the Authentication/Registration/TermsAgreementEnabled switch no longer works. It does—there are just a few extra pieces you need to wire up.
Prerequisites
A live Power Pages site connected to an Azure AD B2C tenant
Portal Management app access
Global admin (or equivalent) rights in both environments
Step 1 – Add your Terms & Conditions copy
Open Portal Management ▶ Content Snippets.
Search for Account/Signin/TermsAndConditionsCopy.
Paste your Terms (HTML is supported). Tip: keep it concise; long text appears in a scrollable panel.
Save & Publish.
Step 2 – Flip the feature flag
Setting | Value | Notes |
---|---|---|
Authentication/Registration/TermsAgreementEnabled | true | Creates the consent dialog. |
Authentication/Registration/TermsPublicationDate | (optional) ISO date‑time | Users are prompted until they accept after this date. |
Step 3 – (Re)test with a fresh user
The dialog appears after the B2C round‑trip but before the contact is fully authenticated. If you’ve ever logged in while the feature was off, your Contact already holds a value in Terms Agreement Date. That suppresses the popup.
Portal Management ▶ Contacts ▶ [contact] ▶ Portal Terms Agreement Date
→ Clear the value and Save or sign in with a brand‑new account in an incognito window.
What you should see
User clicks Sign in.
Redirect to B2C login.
Upon successful auth, the portal displays a modal titled Privacy Notice (or T&C)—with a checkbox and Continue button.
After acceptance the
adx_termsagreementdate
is set and the user lands on the home page.
Troubleshooting
Symptom | Fix |
Dialog never shows | Ensure snippet has content; clear server‑side cache (Portal Designer ▶ Restart site). |
HTML shows as plain text | Make sure Mime Type on the snippet is text/html. |
Shown every time | You left PublicationDate empty—add one so acceptance is sticky. |
Needs re‑wording | Override these snippets: Account/Signin/TermsAndConditionsHeading, …AgreementText, …ButtonText. |
Alternative: push T&C into the B2C sign‑up page
Azure AD B2C → User flows / Custom policies ▶ Page layouts → Company branding:
Terms of use URL
Privacy statement URL
This moves the consent step to the B2C journey and the portal never prompts its own dialog—handier for multi‑app scenarios.
Wrap‑up
With one content snippet, one site setting, and (when needed) a quick field reset, you can keep your legal bases covered even when Power Pages relies solely on Azure AD B2C for authentication.
No comments:
Post a Comment