Cannot use @ Html.LabelFor and <strong> together

I am working with an ASP.Net MVC3 project and I used twitter bootstrap for my project. my problem is that when I used the keyword so that my shortcuts do not work properly. I tried like this

<strong>@Html.LabelFor(model => model.Author)</strong> 

but it is displayed as before. I do not know why.

+4
source share
2 answers

Found a problem. :) Twitterbootstrap.css made this problem.

 label, input, button, select, textarea { font-size: 13px; font-weight: normal; line-height: 18px; } 

when i changed the font size it works correctly. thanks everyone ...

+2
source

Works on my car! :)

If you are having trouble releasing Razor tags, add an extra set of parentheses to it:

 <strong>@(Html.LabelFor(model => model.Author))</strong> 
0
source

All Articles