I am using MVC 3, ASPX pages. I am trying to make an image button for ActionLink: This one works well:
<%: Html.ActionLink("New", "AccessCode", null, new { @class = "but_add" })%>
但这不行!
<%: Html.ActionLink("New", "Create", "CourseChapters",
new { courseId = ViewData["TestId"], @class = "but_add" }, "")%>
我有我的风格。
.but_add
{
background-image: url( ../../Content/images/b_add.gif );
background-repeat: no-repeat;
width: 85px;
height: 27px;
padding-left: 27px;
cursor: pointer;
display: inline-block;
padding-top: 5px;
}