我运行MVC3应用程序时出现浏览器错误

时间:2012-03-22 01:14:02

标签: c# asp.net-mvc asp.net-mvc-3 asp.net-mvc-3-areas

当我尝试编辑或删除浏览器时,我的浏览器出错:

Server Error in '/' Application.
The resource cannot be found.
Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable.  Please review the following URL and make sure that it is spelled correctly.

Requested URL: /console/Delete/PS3

但奇怪的是,当我将鼠标光标放入浏览器地址栏并按下输入删除并编辑页面时

你能帮我解决这个问题。如果您需要任何有关此信息,请告诉我,我将提供。

2 个答案:

答案 0 :(得分:1)

检查是否添加了“/".

的路由

在大多数情况下,这是因为省略了路线。

答案 1 :(得分:0)

我想这是因为相关的动作在它们上定义了[Get]属性,所以添加[Post]属性应该可以解决问题。