I am developing a project having two controllers named as "Student" and "Profile".
public class StudentController : Controller
{
public ActionResult Login(){}
public ActionResult Home(){}
}
public class ProfileController : Controller
{
public ActionResult Details(){}
}
When I am at my Home page after login, it gives me the following url
url:http://localhost:3451/Student/Home?username=student%40gmail.com
and when I click on Ajax based Profile link give below
@Ajax.ActionLink(" ", "Details", "Profile",
new { username = Session["username"].ToString() },
new AjaxOptions()
{
UpdateTargetId = "ajax",
InsertionMode = InsertionMode.Replace,
HttpMethod = "POST",
OnSuccess = "changeUrl(data)" },
new { @class = "glyphicon glyphicon-user",
title = "Profile", style = "color:white;"
})
gives me the Student Profile but url remains same but I want the url to be changed something like that
url:http://localhost:3451/Profile/Details/