locked
Site Definition and Site Template RRS feed

  • Question

  • 1. Is there any way to create a site definition and Site Template through SharePoint  2010 UI??

    2. What is the differences between site definition and site template??

    3. web template and site template  are same thing or different??

    I have searched all above questions but did not able to get satisfactory answer. I need some info on these questions. Please help....

    Saturday, June 2, 2012 8:21 PM

Answers

  • This is maybe the best source to understand site definition vs site templates vs web templates:

    http://blogs.msdn.com/b/vesku/archive/2010/10/14/sharepoint-2010-and-web-templates.aspx

    1. Is there any way to create a site definition and Site Template through SharePoint  2010 UI??

    Site defition (SP 2007 .WSP files): no, this requires use of Visual Studio.

    Site template (SP2007 .STS files, SP2010 .WSP files): yes, just use "save site as template" in site settings, except for publishing sites.

    2. What is the differences between site definition and site template??

    See Vesa's blog post linked above.

    3. web template and site template  are same thing or different??

    Web template (SP2010 .WSP files) is new in SP2010, and the future to replace custom site definitions. Definitely not the same as site templates. You can still use site definitions in SP2010, but it is recommended to use web templates going forwards.

    Sunday, June 3, 2012 1:34 PM

All replies

  • Hi

    check these 2 MS official docs, deppending on your platform

    http://technet.microsoft.com/en-us/library/ff607540.aspx

    http://technet.microsoft.com/en-us/library/ff607735.aspx


    Romeo Donca, Orange Romania (MCSE, MCTS, CCNA) Please Mark As Answer if my post solves your problem or Vote As Helpful if the post has been helpful for you.

    Saturday, June 2, 2012 8:30 PM
  • Hi

    A Site Definition  is a toplevel component that Sharepoint uses to create new sites. Every site is created from a specific site definition.  Site definitions are described in a file called onet.xml , which contain one or more configurations and is the only required component in a site definition. These configurations are rendered on the page as site templates .

    As an example the site definition STS contains 3 configurations, Team Site, Blank Site and Document workspace, but these are called site templates from a user perspective.    Site Definitions exist in the TEMPLATE/SiteTemplates directory; there you will find STS and lots of others.

    Web Templates are localized files that are used to deploy site definitions. These files reside in the TEMPLATE\1033\XML in farms running the US English Sharepoint 2010. These templates contains <Template> elements for each site definition. Sharepoint deploys a core Web Template named webtemp.xml that contains template elemnts for all standard site definitions like this eg. for STS (other site definitions in the web template are omitted) : 

    <Template Name="STS" ID="1">

    <Configuration ID="0" Title="Team Site" Hidden="FALSE" />

    <Configuration ID="1" Title="Blank Site" Hidden="FALSE" />

    <Configuration ID="2" Title="Document Workspace" Hidden="FALSE" />

    </Template>

    To create site definitions you need Visual Studio, it'a complicated process , and it's generally not a recommended approach as you will most probably get into trouble if you later on want to migrate sites based on custom definitions.


    Kind Regards Bjoern
    Blog





    Saturday, June 2, 2012 9:45 PM
  • thanks...it is really useful.
    Sunday, June 3, 2012 7:23 AM
  • So that means, we can not create site definition through UI. The only way is Visual Studio??

    But, Can we create site Template through UI or not??

     
    Sunday, June 3, 2012 7:25 AM
  • As I mentioned,  to create  a site template you need to create a custom site definition and that can't be done in the UI.  Here's an article from Todd Baginski's blog describing how.  http://toddbaginski.com/blog/how-to-create-a-custom-site-definition-in-sharepoint-2010-aspx/ . As you can see there is a manual  approach where you can base your site definition on an existing one by cloning the one you want to extend, customize it, then create the new web template to register it, but still you can't do all this inside the Sharepoint UI.  And if you want to create a new one from scratch, you need Visual Studio


    Kind Regards Bjoern
    Blog


    Sunday, June 3, 2012 11:43 AM
  • This is maybe the best source to understand site definition vs site templates vs web templates:

    http://blogs.msdn.com/b/vesku/archive/2010/10/14/sharepoint-2010-and-web-templates.aspx

    1. Is there any way to create a site definition and Site Template through SharePoint  2010 UI??

    Site defition (SP 2007 .WSP files): no, this requires use of Visual Studio.

    Site template (SP2007 .STS files, SP2010 .WSP files): yes, just use "save site as template" in site settings, except for publishing sites.

    2. What is the differences between site definition and site template??

    See Vesa's blog post linked above.

    3. web template and site template  are same thing or different??

    Web template (SP2010 .WSP files) is new in SP2010, and the future to replace custom site definitions. Definitely not the same as site templates. You can still use site definitions in SP2010, but it is recommended to use web templates going forwards.

    Sunday, June 3, 2012 1:34 PM
  • Can we modify the site definition once it's been created??
    Monday, June 11, 2012 9:30 AM
  • It is unsupported to change a custom site definition after deploying it. It is, however, supported to change a (SP2010) web template as much as you like.
    Monday, June 11, 2012 9:36 AM
  • Thank you for your quick responce.

    But, if we highly need to modify site definition then what should be the best approach with minimum efforts?

    Monday, June 11, 2012 10:05 AM
  • feature stapling is the only supported way of changing a specific site definition after having deployed it: 

    http://blogs.msdn.com/b/vesku/archive/2010/10/14/sharepoint-2010-and-web-templates.aspx

    Monday, June 11, 2012 10:20 AM