As many of you already know you can customize your ADFS login page, a bit.
The default page looks like this and can be a bit anonymous for your company
So I will guide you thru some steps to customize your page with PowerShell scripting
First create a company logo with the size 260×35 pixels and 96 dpi and no greater than 10 KB, save it as logo.png
Second to change the illustration on the left you need a picture with the size 1420×1080 pixels and 96 dpi, and no greater than 200 KB, save it as illustration.png
To apply the pictures use these PowerShell commands
Import-Module ADFSSet-AdfsWebTheme -TargetName default -Logo @{path="c:\temp\logo.png"}Set-AdfsWebTheme -TargetName default -Illustration @{path="c:\temp\illustration.png"}
To customize texts and error descriptions you will need to use the cmdlet Set-AdfsGlobalWebContent, like the Description text below the login form
Set-AdfsGlobalWebContent -SignInPageDescriptionText “This is a private domain.<br>Make sure you are <b>authorized</b>”
Other texts you can modify are
Set-AdfsGlobalWebContent –HomeLinkText
Set-AdfsGlobalWebContent -ErrorPageDescriptionText
Set-AdfsGlobalWebContent -ErrorPageGenericErrorMessage
Set-AdfsGlobalWebContent -ErrorPageAuthorizationErrorMessage
Set-AdfsGlobalWebContent –ErrorPageDeviceAuthenticationErrorMessage
Set-AdfsGlobalWebContent –HelpDeskLink
Set-AdfsGlobalWebContent –HelpDeskLinkText
Set-AdfsGlobalWebContent –HomeLink
Set-AdfsGlobalWebContent –HomeLinkText
Set-AdfsGlobalWebContent –PrivacyLink
Set-AdfsGlobalWebContent –PrivacyLinkText
There are some trickier parts that are possible to change as well. For example these changes
First export the default theme to your computer and create a new ADFS theme with these commands
Import-Module ADFS
Export-AdfsWebTheme -Name default -DirectoryPath c:\Temp\Theme\Custom
New-AdfsWebTheme -Name Custom -SourceName default
Now it’s time to do some scripting, I will not go into details regarding the scripting.
Open the script file you downloaded from “C:\temp\Theme\Custom\script\onload.js” in Notepad
Add this line at the bottom of the script to change the placeholder text in the username input box
document.forms[‘loginForm’].UserName.placeholder = ‘Charles@CustomizedDomainName.Net’;
Add these lines at the bottom of the script to add a text above the login form, this is an example from Microsoft that you can find futher down
// Sample code to change “Sign in with organizational account” string.
// Check whether the loginMessage element is present on this page.
var loginMessage = document.getElementById(‘loginMessage’);
if (loginMessage)
{
// loginMessage element is present, modify its properties.
loginMessage.innerHTML = ‘Your custom company description text’;
}
When you are done and saved your changes it is time to upload the changes to the new created theme we named Custom
Set-AdfsWebTheme -TargetName Custom -AdditionalFileResource @{Uri=’/adfs/portal/script/onload.js’;path=”c:\temp\Theme\Custom\script\onload.js”}
Now don’t forget to apply the changes to set the active theme with this command
Set-AdfsWebConfig -ActiveThemeName Custom
Use these commands to verify your settings
Get-AdfsWebConfig
Get-AdfsGlobalWebContent
It can look like this when you are done!
Happy customization!
Note this is not a complete guide to all possible customizations that you can do!
Source
Thanks, but this didn’t work for ADFS 4.0 under Server 2016. Just an FYI.
LikeLike
Daftar Situs Judi Online Terbaik in Dalam negri
Situsalternatif are a new collection of lists of the greatest online gambling
sites from all popular bookies / providers in Indonesia.
Home elevators online gambling sites listed on this specific page is always altering, because we just provide sites
that will get good testimonials. Each site gives some informative regarding the games obtainable, deposit transaction options,
and alternative hyperlinks.
Collection of Situs Alternatif and Daftar Taruhan online Terbaik
Actively playing on gambling websites is not completely clean, one of many
problems often experienced by players is difficulty accessing the site where to enjoy due to site blocking.
Therefore, the Alternative Site collects alternative links here which usually are incredibly
useful to help gamblers to be able to easily login and daftar
taruhan online. Within addition, you may need to worry about the link jalan keluar judi
that we provide, needless to say an individual can access it easily and with regard to free.
LikeLike
Excellent web site you’ve got here.. It’s difficult
to find excellent writing like yours these days. I honestly appreciate individuals like you!
Take care!!
LikeLiked by 1 person
There is obviously a bunch to realize about this. I feel you made some nice points in features also.
LikeLiked by 1 person
Nice post. I used to be checking continuously this blog and I’m impressed! Very useful info specifically the final phase 🙂 I take care of such information much. I used to be looking for this particular info for a very long time. Thanks and good luck.
LikeLike
I have noticed you don’t monetize your page, don’t waste your traffic, you can earn extra bucks
every month because you’ve got high quality content.
If you want to know how to make extra $$$, search for: Mrdalekjd methods for
$$$
LikeLike
Hi Dear, are you actually visiting this web site regularly, if so after that you will definitely get pleasant knowledge.
LikeLike
Thanks designed for sharing such a pleasant idea, post is pleasant, thats why i have read it fully
LikeLike
Really appreciate your post.
Perfectly working with ADFS 2.1.
Thanks !
LikeLiked by 1 person
What’s up Dear, are you genuinely visiting this website regularly, if so afterward you will definitely obtain nice know-how.
LikeLike
Hi there, yes this paragraph is truly nice and I have learned lot of things from it regarding blogging. thanks.
LikeLiked by 1 person
Thanks , I have just been looking for info about this subject for a long time and yours is the greatest I’ve discovered till now. However, what concerning the bottom line? Are you positive concerning the source?
LikeLike
Hi,
I’m trying to change the size of the left pane on the ADFS Login page. Is there a way to do this. I see there is a way to upload a picture there but couldn’t find anything which could help resize that left pane (also noted as ‘Illustration’ window).
LikeLike
It’s awesome to visit this site and reading the views of all friends concerning this article, while I am also eager of getting know-how.
LikeLike
I’m trying to use the onload.js modifications:
// Sample code to change “Sign in with organizational account” string.
// Check whether the loginMessage element is present on this page.
var loginMessage = document.getElementById(‘loginMessage’);
if (loginMessage)
{
// loginMessage element is present, modify its properties.
loginMessage = ‘Sign in with your email account’;
}
// Code to change “someone@example.com” placeholder in userName input text box.
var userNameInputTextBox = document.getElementById(‘userNameInput’);
if (userNameInputTextBox) {
var placeholderText = ’email.address@mydomain.com’;
if (userNameInputTextBox.placeholder)
userNameInputTextBox.placeholder = placeholderText;
I update it in the custom theme I made in c:\theme
PS C:\Windows\system32> Set-AdfsWebTheme -TargetName custom -AdditionalFileResource @{Uri=”/adfs/portal/script/onload.js”;path=”C:\theme\script\onload.js”}
PS C:\Windows\system32> Set-AdfsWebConfig -ActiveThemeName “custom”
I can see my code in the view source, but the dang elements didn’t change.
Hoping you may have some insight. I changed it back to “default” theme for now.
LikeLiked by 1 person
I can’t see anything in your code that seems wrong. Double check all the ” and ‘, these characters maybe messed up when you copy and paste. If it still does not work, send me a message and attach the onload.js and I will try it out.
LikeLike
Saved as a favorite, I like your site!
LikeLike