Action link in my nav menu

<li>@Html.ActionLink("Log Off", "Logout", "Account")</li>

My Logout.cshtml codes.

@{
  ViewBag.Title = "Log Out";
  Session.Clear();
  FormsAuthentication.SignOut();
  Response.Redirect("~/../Home/Index.cshtml");
}

Why I can't access my logout form?

Recommended Answers

What actually happens?

Jump to Post

All 3 Replies

What actually happens?

now I know what is the reason is.

I didn't have added it in my controller.

:-)

Ok nice one.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.