I don't actually get the "Cancel" button on this screen. It doesn't seem to do anything and just confuses people.
So why not remove it?
This is just another change to onload.js. (See this for how to make a new theme etc.).
// Remove Cancel button for "Update Password" screen
if ( document.getElementById("cancelButton") ) {
document.getElementById("cancelButton").outerHTML = "";
}
Notice the user of "outerHTML" to remove the whole element.
Enjoy!
1 comment:
If you visit the change password page directly it doesn't work. However if you add this to your onload.js.....
// ADFS cancel button on the Update Password page (Expired Password) to redirect back to the original page
var RedirectToPage = function () {
var CurrentUrl = window.location.href;
var UrlParts = CurrentUrl.split("origin=");
var PathParts = UrlParts[1].split("&username=");
var RedirectUrl = UrlParts[0].replace("/adfs/portal/updatepassword", decodeURIComponent(PathParts[0]));
RedirectUrl = RedirectUrl.replace(/&$/, '');
location.href = RedirectUrl;
return false;
}
document.getElementById("cancelButton").onclick = RedirectToPage;
any website that forces you to change your password, the above will redirect you back to that site when you click cancel.
Post a Comment