function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Prashanth SalimattPrashanth Salimatt 

Custom error message in community login page

Hi , 
Thank you in advance.
I want to add custom error message in community login page when deactivated user tried to login he should get "please check your mail "  instead "Your access is disabled. Contact your site administrator." this standard message


User-added image

Please anyone suggest the solution with code in ligntning

Regards,
pachi
AbhishekAbhishek (Salesforce Developers) 
Hi,


I will start with - the message you get on the login page is very secured. You should in fact have messages that way which really do not classify if the username or password was incorrect. That in a way ensures that any unauthorized user does not get any specific information around which field actually was incorrect.

As for customization options - you cannot if you are just using the out of the box configurations. But you do have an option if you customize the login flow by customizing the login component in a combination with login apex controllers for that purpose.

You can find more information on customization options on the help documentation here:

Customize Your Community’s Login Experience (https://help.salesforce.com/articleView?id=networks_customize_login_page.htm&type=5)

Customize Code for Lightning Components on Login Pages (https://help.salesforce.com/articleView?id=networks_custom_login_self_reg_lightning.htm&type=5)


I hope you find the above information is helpful. If it does, please mark as Best Answer to help others too.
​​​​​​​

Thanks.

 
Prashanth SalimattPrashanth Salimatt
Hi Abhishek,

Thanks for quick response.

i have seen the articles but I dont want to  build another login page component , i just want to show the custome error.
If not ,is there any way that on clicking login buttton by deactivate user ,he should be redirect to other page/component in that we can show the error message?(only for inactive user this functionallity works not for other issues such as username/password incorrect)

Regards,
pachi
AbhishekAbhishek (Salesforce Developers) 
No it's not possible.
 
Prashanth SalimattPrashanth Salimatt
Thank you abhishek.
Is there any other solution for this requirment?anyone please
Ruby SullivanRuby Sullivan
Now take the action to go to the admin panel and click on “Custom error message” from the left sidebar under the “Login” section. And again click on the edit button. On this page, you can enter a new message for each of the cases like User missing or Password is wrong Site suspended, etc. You can also make changes to the existing custom messages. I would like to visit https://www.bestdissertation.com/services/stat-project.html website to complete my research paper on time..