Quantcast
Channel: ASPNETWebStack Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 7215

Commented Issue: Unobtrusive validation attributes are double-encoded [1198]

$
0
0
For example:

```html
data-val-equalto="'MyProperty5' and 'MyProperty4' do not match."
```

There's a method called GetValidationAttributes that adds HTML-encoded values to a dictionary, and then the values are encoded again by TagBuilder.
Comments: Hi, I am not able to repro this issue. I have this attribute on my model, ``` [StringLength(100, ErrorMessage = "& ' < >", MinimumLength = 6)] ``` and the resultant html looks like this ``` <input data-val="true" data-val-length="&amp; &#39; &lt; >" data-val-length-max="100" ``` Could you share a repro project?

Viewing all articles
Browse latest Browse all 7215

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>