我应该使用哪个?
<input type="hidden" name="first_name"
value="<%= person.first_name %>" />
或
<input type="hidden" name="first_name"
value="<%= Html.Encode( person.first_name ) %>" />
最佳答案
你应该在 Html.Encode else 字段中加上 "可能会导致注入(inject)问题
关于c# - 我应该在输入字段中对值进行 html 编码吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/428478/