Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

How to find out the created site template

  Asked By: Virendra    Date: Oct 11    Category: Sharepoint    Views: 2758

is there a way to find out what site template was used when a site was
created in the very beginning?



3 Answers Found

Answer #1    Answered By: Himanshu Gohil     Answered On: Oct 11


Answer #2    Answered By: Ashton Schroeder     Answered On: Oct 11


SPWeb.Configuration property

"Gets the ID of the configuration in the site  definition that was used to create
the site or the ID of the configuration in the site definition from which
derives the site template  that was used to create the site."

"A 16-bit integer that indicates the ID of the configuration. This value
corresponds to the ID attribute of the Configuration Element (Site) element in
Collaborative Application Markup Language Core Schemas (CAML)."

Answer #3    Answered By: Iris Ballard     Answered On: Oct 11

spweb.WebTemplate will give you a code name for the template  (like "STS"). To
find out a display name you'll need to use GetWebTemplates function

function and pass in the language code (1033 -en-US)

SPWebTemplateCollection templates = spweb.Site.GetWebTemplates(1033);

then you can get it by getting

Didn't find what you were looking for? Find more on How to find out the created site template Or get search suggestion and latest updates.