SSO Redirection to SSO Login Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-24-2023 10:40 PM - edited ‎10-24-2023 10:42 PM
Hi All,
We have 2 buttons in the login page for the SSO. I have created a system property with the value of the sys_id of the IdP. When the button (Login1/MS Login) is clicked it goes to a logout/timeout.do then goes back to the login page. Is there any code I am lacking? So after the logging in to the SSO, it will redirect you to the portal (/customer_portal). Thank you very much.
HTML Template:
Server Script:
System property:

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-25-2023 12:06 AM
Hi @Rairai31,
Take a look at the OOTB login widget (https://instance.service-now.com/nav_to.do?uri=sp_widget.do?sys_id=6506d341cb33020000f8d856634c9cdc)
The navigation is handled within the client script, not within the HTML part.
Help others to find a correct solution by marking the appropriate response as accepted solution and helpful.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-25-2023 12:34 AM
Hello @Rairai31
- Ensure the System Property glide.entry.first.page.script to new SPEntryPage().getFirstPageURL().
- Modify line Script Include SPEntryPage around line 69 to add something like follows:
// Redirect all users to a custom page, unless SP or redirect
if (!redirectURL && !isServicePortalURL)
return 'your_custom_page.do';
Plz mark my solution as Accept, If you find it helpful.
Regards,
Samaksh