我浏览网页寻找解决方案我在我的页面上有三个标签收件箱,发送和删除如下所示
<li class="active">
<a href='@Url.Action("UserEmails", "Profile", routeValues: new { area = "Profile", s = (int)Enums.EmailStatus.Inbox })'>
<i class="blue ace-icon fa fa-inbox bigger-130"></i>
<span class="bigger-110">Inbox</span>
</a>
</li>
<li>
<a href='@Url.Action("UserEmails", "Profile", routeValues: new { area = "Profile", s = (int)Enums.EmailStatus.Sent })'>
<i class="orange ace-icon fa fa-location-arrow bigger-130"></i>
<span class="bigger-110">Sent</span>
</a>
</li>
<li>
<a href='@Url.Action("UserEmails", "Profile", routeValues: new { area = "Profile", s = (int)Enums.EmailStatus.Deleted })'>
<i class="red ace-icon glyphicon glyphicon-trash bigger-130"></i>
<span class="bigger-110">Deleted</span>
</a>
</li>
正如您所看到的,我已经指定了我要求它回传到点击时的URL,这是我的控制器
[HttpGet]
public ActionResult UserEmails(int s) // Called when the view is requested for the first time
{
try
{
_userEmails = GetUserEmails(s);
}
catch (Exception e)
{
Console.WriteLine(e);
}
return View(_userEmails);
}
现在当我点击标签时它没有发回,有人可以启发我为什么不是这样的?