ASP.NET MVC 2 验证器的全球化
是否有办法覆盖 ValidationAttributes 中的自定义验证错误消息?
基本上我需要 ValidationAttributes 来支持全球化。
Is there anyway to override the custom validation error messages from the ValidationAttributes?
Basically I need the ValidationAttributes to support globalization.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我在 ScottGu 的博客上看到了一个关于它的问题,他回答说,如果你正在使用 DataAnnotations。你是?
更新:我在看其他一些东西并发现了这篇文章。我认为它可能对您或其他可能偶然发现它的人有帮助。
http:// blog.maartenballiauw.be/post/2009/11/05/Localize-ASPNET-MVC-2-DataAnnotations-validation-messages.aspx
I saw a question on ScottGu's blog about it and he responded with, that is if you are using DataAnnotations. Are you?
UPDATE: I was looking at some other stuff and came across this article. Thought it might help you, or anyone else that may stumble across it.
http://blog.maartenballiauw.be/post/2009/11/05/Localize-ASPNET-MVC-2-DataAnnotations-validation-messages.aspx