Forum Discussion
apply pnp template on sub site
- DeletedOct 31, 2016
Hi,
it seems the pages are not in the current directory. My pnp:files look like this
<pnp:File src="SiteAssets\Logo.png" Folder="SiteAssets" Overwrite="true" />
where src could be C:\temp\sitesassets\logo.png
so whitout properties
but also do you need to provision the masterpages? If they are already in there why would you like to upload your version?
hope it helps.
Hi,
looked at your template and what i would do narrow it down meaning remove parts of the xml like what happeens if all is commented out except time... etc..
furthermore i see this line:
<pnp:Property Key="PublishingPageLayout" Value="{sitecollection}/_catalogs/masterpage/wizdom2Column.aspx, https://xxxx.sharepoint.com/sites/rayhan{sitecollection}/_catalogs/masterpage/wizdom2Column.aspx" />
Wher you use a url and a sitecolleciton token in 1 url...
Thanks for your help
- DeletedOct 31, 2016
Hi,
it seems the pages are not in the current directory. My pnp:files look like this
<pnp:File src="SiteAssets\Logo.png" Folder="SiteAssets" Overwrite="true" />
where src could be C:\temp\sitesassets\logo.png
so whitout properties
but also do you need to provision the masterpages? If they are already in there why would you like to upload your version?
hope it helps.
- Jess LassenNov 01, 2016Copper Contributor
Deleted one thing, I told you it works, but it only works from PowerShell but not from C# console application, can you give any clue? By the way, this time I am using .pnp template.
Thanks
- DeletedNov 01, 2016
Hi Jess,
please make sure youre files are in the correct directory aka the bin directory where your console is running.
kr,
Paul
- Jess LassenNov 01, 2016Copper ContributorThanks a lot for your help. When I modified file src from "default.aspx" to "Pages\default.aspx" it worked! I don't know why provisioning engine does not giving the correct path for file src. May be I am extracting template from sub site, that's why.
Anyway, thanks for the big help.