YouaredevelopinganASP.NETMVC2application.Aviewcontainsaformthatallowsuserstosubmittheirfirstname.Youneedtodisplaythevaluethatissubmitted,andyoumustensurethatyourcodeavoidscross-sitescripting.Whichcodesegmentshouldyouuse?()A.<%:Model.FirstName%>B.<%=Model.

题目

YouaredevelopinganASP.NETMVC2application.Aviewcontainsaformthatallowsuserstosubmittheirfirstname.Youneedtodisplaythevaluethatissubmitted,andyoumustensurethatyourcodeavoidscross-sitescripting.Whichcodesegmentshouldyouuse?()

A.<%:Model.FirstName%>

B.<%=Model.FirstName%>

C.<%Response.Write(Model.FirstName)%>

D.<%Response.Write(HttpUtility.HtmlDecode(Model.FirstName))%>


相似考题