Thursday, December 26, 2013

What is Site Definition and Site Template in SharePoint 2010?

The description about the Site Definition and Site Template as below:

What is a Site Definition in SharePoint 2010?

It’s a methods for providing prepackaged site and list content.

Site Definition consists of XML and ASPX pages stored in the 14 Hive folder. You can locate them in the following folder:

C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\SiteTemplates

You can create Site Definition by using Visual Studio-
  • Open Visual Studio in Elevated Permissions mode and use File > New Project > SharePoint > Site Definition.
  • Once the Site definition project is created, add a new Visual Web Part into it and then write your logic for created webpart. You have to specify the Visual Web Part in the Default.aspx of the site definition file to add it.
  • For deploying the site definition, you can right click on the project and select Deploy
  • The project gets deployed to the SharePoint site selected while project creation.

What is a Site Template in SharePoint 2010?


A template is a pre-defined set of functions or settings that can be used over time. 

There are many templates within SharePoint- Site Templates, Document Templates, Document Library and List Templates.

You can use these templates as they are to create your own SharePoint site and then customize the site according to your requirement.

SharePoint 2010 comes bundled with a lot of default site templates like Team Site, Blog site, and Group Work Site.

Related Posts: