Announcements
Hi,
I want to open Sign In Page directly, when any one hit the Portal URL.
Can we redirect Home page on Sign-In page?
Can we applied any other approach for that?
Please suggest me good solution?
Thanks!
Hi Cristina,
When you are redirecting user from homepage to sign in page, what happens when they sign in. They will again be redirected to the sign in page. I think for first time user it will be the profile page after they sign in. Probably, you need to place a condition if the user is not signed in then redirect.
Best Regards
PG
Hi Partner,
You could add custom JS code in Home webpage to do this.
Please refer to the following steps.
1.Go to Dynamics 365 Portal Management and find your Home web page for your website.
2.Open the record and in "Localized Content" session, open the "Home" record again.
3.In "Advanced" tab, use the following JS code.
$(function () { var url = document.location.toString(); var arrUrl = url.split("//"); var start = arrUrl[1].indexOf("/"); var relUrl = arrUrl[1].substring(start 1,start 7); if(relUrl==null||relUrl==""||relUrl==undefined||relUrl!="SignIn"){ window.location.href="SignIn"; } })
Save and wait the settings sync to Portal.
Then when you go to the portal URL directly, the page will be redirected to SignIn page as you wish.
Regards,
Leo
André Arnaud de Cal...
294,125
Super User 2025 Season 1
Martin Dráb
232,871
Most Valuable Professional
nmaenpaa
101,158
Moderator