Quantcast
Channel: SharePoint 2013 - Development and Programming forum
Viewing all articles
Browse latest Browse all 7589

Custom Web template based on Team Site is empty

$
0
0

Hi all,

Following is the process I followed to create a Custom Web Template based on Team Site in SP 2013. I opened VS 2012 created an "empty SharePoint project", added an "Empty Element", changed its elements.xml file as follows and added a copy of onet.xml from 15Hive\TEMPLATE\SiteTemplates\sts\xml to the "empty element", changed the deployment type property of the onet.xml file to ElementFile. I Added a web scoped feature to the project and deployed it. 
elements.xml:

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
  <WebTemplate
    Name="Same_Name_as_EmptyElement"
    BaseTemplateName="STS"
    BaseTemplateID="1"
    BaseConfigurationID="0"
    Title="MyTeamSite"
    Description="blah"
    DisplayCategory="MyTemplates"/>
</Elements>


Everything works great, When I want to create a new sub site, I can find my template and create a new Sub Site based on it. But the page is empty. There is no Promoted Links, or Documents Library, nothing. SitePages/Home.aspx is completely empty. why? and how Can I solve it? thanks for helping me.

UPDATE: I have tried to copy default.aspx and defaultdws.aspx as well to the template to deploy them but still same problem.





Viewing all articles
Browse latest Browse all 7589

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>