I have a view named UserVerify with a returnUrl parameter, http://localhost:50383/register/UserVerify?returnUrl=http%3A%2F%2Flocalhost%3A50383%2Fregister%2Forganization.
The UserVerify view has a partial view control, LogonControl.
<% Html.RenderPartial("LogonControl"); %>
Here is the controller code for the LogonController
public ActionResult LogonControl(string returnUrl)
{
return View();
}
[HttpPost]
public ActionResult LogonControl(LogOnModel model,string returnUrl)
{
if (!String.IsNullOrEmpty(returnUrl))
{
return Redirect(returnUrl);
}
else
{
return RedirectToAction("Index", "Public");
}
}
When I test, the returnUrl is not getting set, it is null. Any ideas on how to get the returnUrl down to the partial view?
Thanks