Share via

Site Definition (Onet.xml) Files

Applies to: SharePoint Foundation 2010

In an Onet.xml file, the Feature element is used within a site definition configuration to contain a reference to a Feature instance and default property values. The Configuration element specifies lists and modules to use when creating SharePoint sites. For information about the format and elements used in site definitions, see Site Schema.

SharePoint Foundation activates Features specified within the Onet.xml file in the order that they are listed. Consequently, you must specify Features that are depended upon before Features that depend upon them.


The following example shows the Feature element used to specify Features and Feature properties in a site definition configuration.

<Configuration ID="0" Name="Publishing"> 
      <List Title="Web Part Gallery" Type="113" Url="_catalogs/wp" 
         RootWebOnly="True" />
      <Feature ID="AEBC918D-B20F-4a11-A1DB-9ED84D79C87E"/>
      <Feature ID="22A9EF51-737B-4ff2-9346-694633FE4416">
         <Properties xmlns="">
            <Property Key="ChromeMasterUrl" Value=""/>
            <Property Key="WelcomePagePageLayoutUrl" Value=""/>
            <Property Key="WelcomePageUrl" Value=""/>
      <Feature ID="23BCB938-F4B5-42a4-8050-F8CB92EF4078">
         <Properties xmlns="">
            <Property Key="CopyLayouts" Value="true"/>

See Also


Understanding Onet.xml Files

Site Schema

Understanding WebTemp*.xml Files