deichor
deichor
CC#
Created by deichor on 11/17/2023 in #help
✅ Blazor Tutorial (Todo List) Doesn't Work
.closed
4 replies
CC#
Created by deichor on 11/17/2023 in #help
✅ Blazor Tutorial (Todo List) Doesn't Work
closed.
4 replies
CC#
Created by deichor on 11/17/2023 in #help
✅ Blazor Tutorial (Todo List) Doesn't Work
/closed
4 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
No description
15 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
Dude form is work, I need disable refresh form
15 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
wdym? it is default form.
15 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
I need it to literally refresh the page not the form.
15 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
Yes, I fixed it, but when I refresh it, it sends the form again.
15 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
I tried ViewData.clear but it is same
15 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
What is wrong?
15 replies
CC#
Created by deichor on 11/9/2023 in #help
✅ How to clear old ViewData in ASP.NET?
The wrong password message still appears when I refresh the page.
15 replies
CC#
Created by deichor on 11/4/2023 in #help
✅ How to clear old message on refresh page?
public class UserController : Controller
{
// GET
[HttpGet]
public IActionResult Login()
{
return View();
}

// get login datas
[HttpPost]
public async Task<IActionResult> Login(string username, string password)
{
LoginMatcher lm = new LoginMatcher(username, password);
User? user = lm.Loginner();
if (user != null)
{
Console.Out.WriteLine("giriş başarılı");
return Json(new { status="error",message="acces accept"});
}
else
{
ViewData["Login"] = "wrong_password";
return View();
}

}
}
public class UserController : Controller
{
// GET
[HttpGet]
public IActionResult Login()
{
return View();
}

// get login datas
[HttpPost]
public async Task<IActionResult> Login(string username, string password)
{
LoginMatcher lm = new LoginMatcher(username, password);
User? user = lm.Loginner();
if (user != null)
{
Console.Out.WriteLine("giriş başarılı");
return Json(new { status="error",message="acces accept"});
}
else
{
ViewData["Login"] = "wrong_password";
return View();
}

}
}
7 replies
CC#
Created by deichor on 11/4/2023 in #help
✅ How to clear old message on refresh page?
@if (ViewData["Login"] == "wrong_password")
{

<div class="login-wrong-password">
<span>Kullanıcı adı veya parola hatalı!</span>
</div>

}

@if (ViewData["Login"] == "wrong_password")
{

<div class="login-wrong-password">
<span>Kullanıcı adı veya parola hatalı!</span>
</div>

}

7 replies