With the following service settings below, I can log in to Twitter, Hotmail, Facebook.
Noting that my project at creation time enabled the individual login option
services.AddAuthentication()
.AddTwitter(twitterOptions =>
{
twitterOptions.ConsumerKey = "#######";
twitterOptions.ConsumerSecret = "#######";
})
.AddFacebook(facebookOptions =>
{
facebookOptions.AppId = "#######";
facebookOptions.AppSecret = "#######";
})
.AddMicrosoftAccount(microsoftOptions =>
{
microsoftOptions.ClientId = "#######";
microsoftOptions.ClientSecret = "#######";
});
With service settings made:
- I want to create a page that will be the initial
- The home page will only have logins buttons through social networks
- Example of the page I want to do this below.
The question is:
How do I configure the buttons with images of social networks within a custom page in Asp.Net Core 2.1 to perform the logins
Asp.Net MVC has the following configuration inside _ExternalLoginListPartial.cshtml
@using Microsoft.Owin.Security
@foreach (AuthenticationDescription p in loginProviders)
{
<button type="submit" class="btn btn-default" id="@p.AuthenticationType" name="provider" value="@p.AuthenticationType" title="Faça login usando sua conta @p.Caption">@p.AuthenticationType</button>
}