Click here to Skip to main content
14,332,494 members

Web Development

AnswerRe: object vs img Pin
Richard Deeming5-Jul-18 1:50
mveRichard Deeming5-Jul-18 1:50 
GeneralRe: object vs img Pin
V.5-Jul-18 18:50
professionalV.5-Jul-18 18:50 
Questionstudent information Pin
Raja Jee2-Jul-18 18:31
memberRaja Jee2-Jul-18 18:31 
AnswerRe: student information Pin
Richard MacCutchan2-Jul-18 21:11
protectorRichard MacCutchan2-Jul-18 21:11 
QuestionCode Stopped Working When Controller Method Is Invoked Using AJAX Instead Of Formaction Pin
MadDashCoder24-Jun-18 1:23
memberMadDashCoder24-Jun-18 1:23 
AnswerRe: Code Stopped Working When Controller Method Is Invoked Using AJAX Instead Of Formaction Pin
Richard Deeming24-Jun-18 5:04
mveRichard Deeming24-Jun-18 5:04 
QuestionMy First Web API Pin
Kevin Marois20-Jun-18 8:47
professionalKevin Marois20-Jun-18 8:47 
AnswerRe: My First Web API Pin
Richard Deeming20-Jun-18 10:53
mveRichard Deeming20-Jun-18 10:53 
I'd be inclined to make it a POST request, so that the credentials aren't exposed in the URL. (Although hopefully you're using SSL, which reduces that risk.)

Something like this:
public UserEntity Login([FromBody] CredentialEntity credentials)
    var connString = "";
    var appSec = new ApplicationSecurity(connString);
    return appSec.IsUserLoggedIn ? appSec.CurrentUser : null;

To test it in the browser, you'd need a form with the method set to POST and the action set to api/Login/Login. Alternatively, you could use a proper REST tool like Postman or Insomnia, which will give you more control over the request.

"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer

GeneralRe: My First Web API Pin
Kevin Marois20-Jun-18 10:59
professionalKevin Marois20-Jun-18 10:59 
GeneralRe: My First Web API Pin
Richard Deeming21-Jun-18 12:19
mveRichard Deeming21-Jun-18 12:19 
QuestionPassing jqGrid Data To Server-Side Method Pin
MadDashCoder16-Jun-18 1:54
memberMadDashCoder16-Jun-18 1:54 
QuestionHow you do make user list Pin
Nuxyer13-Jun-18 5:38
memberNuxyer13-Jun-18 5:38 
AnswerRe: How you do make user list Pin
David Mujica14-Jun-18 3:03
memberDavid Mujica14-Jun-18 3:03 
Questionwhere to post CSS questions? Pin
piano001113-Jun-18 0:38
memberpiano001113-Jun-18 0:38 
AnswerRe: where to post CSS questions? Pin
Nuxyer13-Jun-18 5:41
memberNuxyer13-Jun-18 5:41 
QuestionGet more than 1 data entry from DB using PHP Pin
Member 1386791311-Jun-18 4:01
memberMember 1386791311-Jun-18 4:01 
AnswerRe: Get more than 1 data entry from DB using PHP Pin
Jochen Arndt11-Jun-18 22:55
mveJochen Arndt11-Jun-18 22:55 
GeneralRe: Get more than 1 data entry from DB using PHP Pin
Member 1386791312-Jun-18 2:34
memberMember 1386791312-Jun-18 2:34 
QuestionSignalR - resources Pin
0x01AA9-Jun-18 9:15
professional0x01AA9-Jun-18 9:15 
QuestionMagento 2: config url rewrite? Pin
Vicent Nguyen7-Jun-18 18:06
professionalVicent Nguyen7-Jun-18 18:06 
Questionhow to merge two powerpoint presentation slides into one ppt using php or javascript ? Pin
Member 1385293031-May-18 2:22
memberMember 1385293031-May-18 2:22 
QuestionMVC - Video chat with my screen sharing web Pin
Gunasekararan30-May-18 1:24
professionalGunasekararan30-May-18 1:24 
QuestionIs this code correct? Pin
X2A coding25-May-18 4:28
professionalX2A coding25-May-18 4:28 
QuestionRe: Is this code correct? Pin
Richard MacCutchan25-May-18 4:35
protectorRichard MacCutchan25-May-18 4:35 
Questionpython webdevelopment Pin
Member 1384376324-May-18 21:49
memberMember 1384376324-May-18 21:49 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.