在Html.ActionLink中运用二维判断语句

@Html.ActionLink("公告信息", "notice", "article", null, new { @class = ViewData["getclass"]!="notice"?"":"currclass" })
@Html.ActionLink("历史查询", "index", "home", new { hd = DateTime.Today.ToString("yyyy-MM-dd") }, new { @class = ViewData["getclass"] == "order" && Request["hd"] != null ? "currclass" : "" })
原文地址:https://www.cnblogs.com/firstcsharp/p/3143787.html