Set a web template’s welcome page URL declaratively without using the publishing feature

To set a custom welcome page in a web template using no-code and no-publishing, do the following

  1. Create a web-scoped feature, e.g. WebTemplatePropertyBagFeature
  2. Add your code to an element like the one below (I am keeping a webtemplate id value property, just to show how you can have multiple values set via one single property bag feature):
<?xml version="1.0" encoding="utf-8"?> <Elements xmlns="http://schemas.microsoft.com/sharepoint/"> <PropertyBag ParentType="Web"> <Property Name="Readify.Pwcs.Intranet.Collaboration.WebTemplateId" Type="string" Value="PWCSTeamSite" /> </PropertyBag> <PropertyBag Url="" ParentType="Folder" RootWebOnly="FALSE"> <Property Name="vti_welcomepage" Type="string" Value="SitePages/Home.aspx" /> </PropertyBag> </Elements>

ServerTemplate values–“<Lists ServerTemplate=’301’ />”

When creating a list or writing site data query (using SPSiteDataQuery) we all need to indicate the value for “ServerTemplate” attribute, I will leave a list here for my own reference and for anyone who may need these values:

100

Generic list

101

Document library

102

Survey

103

Links list

104

Announcements list

105

Contacts list

106

Events list

107

Tasks list

108

Discussion board

109

Picture library

110

Data sources

111

Site template gallery

112

User Information list

113

Web Part gallery

114

List template gallery

115

XML Form library

116

Master pages gallery

117

No-Code Workflows

118

Custom Workflow Process

119

Wiki Page library

120

Custom grid for a list

130

Data Connection library

140

Workflow History

150

Gantt Tasks list

200

Meeting Series list

201

Meeting Agenda list

202

Meeting Attendees list

204

Meeting Decisions list

207

Meeting Objectives list

210

Meeting text box

211

Meeting Things To Bring list

212

Meeting Workspace Pages list

300

Portal Sites list

301

Blog Posts list

302

Blog Comments list

303

Blog Categories list

850

Page Library

1100

Issue tracking

1200

Administrator tasks list

2002

Personal document library

2003

Private document library