Interviews2 answers
Explain the following: a.) SPSite b.) SPWeb
2 Answers
Both are classes of SharePoint Server side object model. Under SharePoint web application, you can have multiple site collections and under a site collection you can have multiple sites/subsites. To access/update site collection properties, object of SPSite class is used. And to access/update root site of site collction or sub site properties, object of SPWeb class is used.
Akshay DeshmukhPosted Jul 11, 2017, 2:08 AM EDT
a.) SPSite -
i.)It is a site collection and an be represented as SPSite class in the object model.
ii.)SPSite object is a primary entry points to the server object model.
iii.)It is used frequently in SharePoint application development.
b.) SPWeb -
i.) It is a specific site under site collection in Sharepoint.
ii.) It is represented as SPWeb class in the server object model.
Ramesh PalaniappanPosted Aug 18, 2016, 3:39 AM EDT

