开发者

Razor Syntax / WebMatrix - C#

I'm just starting out with WebMatrix and would like to know how to style a @Html.TextBox("email") and @Html.Password("password") control?

I've tried (in my CSS file):

.email{
   /* styles here */
}

.password{
   /* styles here */
}

But that has no effect at all. How can we style these types 开发者_开发技巧of controls?


You can indicate what class to use when creating the text box with an anonymous type like so: @Html.TextBox("Email", null, new { @class="email" })

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜