Explain the role of AllowUnsafeUpdates.- AllowUnsafeUpdates allows updates on a GET request. - It basically allows code to bypass security validation while making changes to Sharepoint objects which are not executed within a HTTP POST request. - It will get or set a Boolean value that will specify whether to allow updates to the database as a result of a GET request or without requiring a security validation. - We need to set SPWeb.AllowUnsafeUpdates = true whenever the code modifies the SharePoint data in some way or whenever an update is needed on the SharePoint objects like SPWeb, SPList, SPListItem etc without requiring a security validation.
|