我需要添加一个htmlAttribute到我的复选框。所以,我这样做,我认为像这样:MVC本地化htmlAttributes
@ Html.CheckBoxFor(型号=> model.IsVisibleFirstLastName,新{@class = “privacyCheck工具提示”,@title = “@ Resources.fld_CountryVisibleChk_lbl”})
其中Resources.fld_CountryVisibleChk_lbl
是我的资源文件(resx)条目。
但这不起作用。我只能得到确切的字符串@Resources.fld_CountryVisibleChk_lbl
(在浏览器中查看源代码时)而不是实际值(即与语言相关的字符串)。 感谢
是做到了。谢谢。 DUH! - 傻我 – ShaneKm
@ShaneKm它发生在我们身上! – James