Microsoft
70-519 · Question #121
You are designing an ASP.NET Web application. A page of the Web application will allow users to post comments and view comments posted by other users. You need to recommend an approach for…
The correct answer is C. On the page, set the ValidateRequest property of the @ Page directive to false. See the full explanation below for the reasoning.
Question
You are designing an ASP.NET Web application. A page of the Web application will allow users to post comments and view comments posted by other users. You need to recommend an approach for preventing the Web application from storing malicious content. What should you recommend?
Options
- AIn the page code-behind, add a Validatelnput attribute.
- BOn the page, set the ValidateRequest property of the @ Page directive to false.
- COn the page, set the ValidateRequest property of the @ Page directive to false.
- DIn the page code-behind, add a Validation attribute.
How the community answered
(32 responses)- A6% (2)
- B13% (4)
- C78% (25)
- D3% (1)
Community Discussion
No community discussion yet for this question.