ActionLink with multiple classes in ASP.NET MVC3

I'm curious if it's possible to use multiple CSS classes in ActionLink in MVC3 Razor syntax? In the line below, only the first class (btn) and skipps btn_c are loaded.

@Html.ActionLink("Administration", "Index", "Admin", null, new { @class = "btn btn_c" }) 
+4
source share
1 answer

I just used your current ActionLink with the following css:

 .btn { color: yellow; } .btn_c { background-color: red; } 

And he successfully produced the following output:

Linkoutput

+2
source

Source: https://habr.com/ru/post/1385757/


All Articles