Hi all I am new to MVC3 have written a code for login using MVC3 architecture every thing works fine, now I would like to display the user information after he logs in. How can I develop the code in MODEL , I would like to get the results with out using linq and Enity framework.
[HttpPost, ValidateInput(false)]
public ActionResult LogOn(Login model)
{
if (ModelState.IsValid)
{
if (model.IsUserExist(model.EmailId, model.Password))
{
ViewBag.UserName = model.EmailId;
//I tried this which didn't worked
//if (model.select(model.EmailId))
//{
// return RedirectToAction("Display", "Home");
// }
// here I would like to code to show the data of the one who logged in with Edit, delete options
}
else
{
ModelState.AddModelError("", "EmailId or Password Incorrect.");
}
}
return View(model);
}