Search code examples
c#asp.netasp.net-mvchtml.actionlink

How to use class in ActionLink in asp.net mvc?


Here The upper line is in html while lower is in asp.net but I am not getting the output from lower line as the upper gives.

The output with upper line is first one and the output of lower line is second one.

Why I am not getting the desired output?


Solution

  • You can try this

    <li>@Html.ActionLink("Basic Information", "Index", "EditProfile", new { }, new { @class = "active icon ion-ios-information-outline" })</li>