This is target controller and action:
[RoutePrefix("Editor")]
public class EditorController : Controller
[HttpGet]
[Route("{id:int}")]
public ActionResult Edit(int id)
Map method calling:
@Url.Action("Edit", "Editor", new { id = page.Id})
result: /Editor?id=1
required result: /Editor/1
To achieve the result you want you have to use a route name:
Then in your view you would use Url.RouteUrl instead of Url.Action:
Hope this helps,
I just faced with same problem. When i fixed the links - editing is broken (form always redirects to the same page).
Here is solution:
A link
A form in the view Edit.cshtml (specifying Controller name is necessary!)
The actions in the controller
Now both links and editing works.
Have you checked if you have enabled MVC AttributeRoutes?
see http://blogs.msdn.com/b/webdev/archive/2013/10/17/attribute-routing-in-asp-net-mvc-5.aspx