Skip to content

Commit d1c493f

Browse files
committed
doc updates
1 parent dd7ff8c commit d1c493f

File tree

2 files changed

+98
-0
lines changed

2 files changed

+98
-0
lines changed

docs/transform/modernize-userinterface-site-pages-dotnet.md

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,65 @@ using (var cc = am.GetSharePointOnlineAuthenticatedContextTenant(siteUrl, userNa
5252
}
5353
```
5454

55+
## FAQ
56+
57+
### I choose the "AddPageAcceptBanner" option but don't see the banner web part on the created pages
58+
59+
In order to make the banner webpart work there are 2 requirements that have to be met:
60+
61+
- The banner web part must have been installed in your tenant app catalog
62+
- The banner web part must have been referenced in the used webpartmapping.xml file
63+
64+
#### Installing the banner web part
65+
66+
To install the default banner web part follow these steps:
67+
68+
- Open your tenant app catalog site collection and go to the **Apps for SharePoint** list
69+
- Download the banner web part solution (**sharepointpnp-pagetransformation-client.sppkg**) from the [sp-dev-modernization](https://github.com/SharePoint/sp-dev-modernization/blob/master/Solutions/PageTransformationUI/assets/sharepointpnp-pagetransformation-client.sppkg?raw=true) repository
70+
- Drag and drop the sppkg file in the **Apps for SharePoint** list. Doing so will ask to **make this solution available to all sites in your organization**. Check the box and click on **Deploy**.
71+
72+
> [!NOTE]
73+
> The page banner web part is configured to **not** be visible in the web part picker...so even if you've deployed it to all sites in your tenant it will still not be visible for your users. It can only programmatically be added to a page
74+
75+
#### Checking your webpartmapping.xml file
76+
77+
When the page transformation engine puts the banner web part on a page it gets it's definition from the webpartmapping.xml file. Check if you find a web part of type **SharePointPnP.Modernization.PageAcceptanceBanner** in your mapping file. Below sample shows the default configuration using the default web part uploaded in the previous step.
78+
79+
```xml
80+
<WebPart Type="SharePointPnP.Modernization.PageAcceptanceBanner">
81+
<Properties>
82+
<Property Name="SourcePage" Type="string"/>
83+
<Property Name="TargetPage" Type="string"/>
84+
</Properties>
85+
<Mappings>
86+
<Mapping Default="true" Name="default">
87+
<ClientSideWebPart Type="Custom" ControlId="d462a7c4-b2e1-4e80-867a-7b46d279c161" Order="10" JsonControlData="&#123;&quot;serverProcessedContent&quot;:&#123;&quot;htmlStrings&quot;:&#123;&#125;,&quot;searchablePlainTexts&quot;:&#123;&#125;;imageSources&quot;:&#123;&#125;,&quot;links&quot;:&#123;&#125;&#125;,&quot;dataVersion&quot;:&quot;1.0&quot;,&quot;properties&quot;:&#123;&quot;description&quot;:&quot;modernizationPageDemo&quot;,&quot;sourcePage&quot;:&quot;ePage}&quot;,&quot;targetPage&quot;:&quot;{TargetPage}&quot;&#125;&#125;"/>
88+
</Mapping>
89+
</Mappings>
90+
</WebPart>
91+
```
92+
93+
> [!NOTE]
94+
> You can use your own custom banner web part by simply deploying it and then updating the mapping in the used webpartmapping.xml file.
95+
96+
### Modern site pages don't work on the site I want to transform pages in
97+
98+
By default the modern site page capability is enabled on most sites but maybe it was turned off afterwards. If that's the case the [SharePoint Modernization scanner](https://aka.ms/sppnp-modernizationscanner) will tell you which sites have turned of the modern page feature. To remediate this use below sample PnP PowerShell script:
99+
100+
```PowerShell
101+
$minimumVersion = New-Object System.Version("2.24.1803.0")
102+
if (-not (Get-InstalledModule -Name SharePointPnPPowerShellOnline -MinimumVersion $minimumVersion -ErrorAction Ignore))
103+
{
104+
Install-Module SharePointPnPPowerShellOnline -MinimumVersion $minimumVersion -Scope CurrentUser
105+
}
106+
Import-Module SharePointPnPPowerShellOnline -DisableNameChecking -MinimumVersion $minimumVersion
107+
108+
Connect-PnPOnline -Url "<your web url>"
109+
110+
# Enable modern page feature
111+
Enable-PnPFeature -Identity "B6917CB1-93A0-4B97-A84D-7CF49975D4EC" -Scope Web -Force
112+
```
113+
55114
## See also
56115

57116
- [Modernize your classic SharePoint sites](modernize-classic-sites.md)

docs/transform/modernize-userinterface-site-pages-powershell.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,45 @@ TargetPageTakesSourcePageName | $false | The default behavior is to give the cre
3737

3838
## FAQ
3939

40+
### I choose the "AddPageAcceptBanner" option but don't see the banner web part on the created pages
41+
42+
In order to make the banner webpart work there are 2 requirements that have to be met:
43+
44+
- The banner web part must have been installed in your tenant app catalog
45+
- The banner web part must have been referenced in the used webpartmapping.xml file
46+
47+
#### Installing the banner web part
48+
49+
To install the default banner web part follow these steps:
50+
51+
- Open your tenant app catalog site collection and go to the **Apps for SharePoint** list
52+
- Download the banner web part solution (**sharepointpnp-pagetransformation-client.sppkg**) from the [sp-dev-modernization](https://github.com/SharePoint/sp-dev-modernization/blob/master/Solutions/PageTransformationUI/assets/sharepointpnp-pagetransformation-client.sppkg?raw=true) repository
53+
- Drag and drop the sppkg file in the **Apps for SharePoint** list. Doing so will ask to **make this solution available to all sites in your organization**. Check the box and click on **Deploy**.
54+
55+
> [!NOTE]
56+
> The page banner web part is configured to **not** be visible in the web part picker...so even if you've deployed it to all sites in your tenant it will still not be visible for your users. It can only programmatically be added to a page
57+
58+
#### Checking your webpartmapping.xml file
59+
60+
When the page transformation engine puts the banner web part on a page it gets it's definition from the webpartmapping.xml file. Check if you find a web part of type **SharePointPnP.Modernization.PageAcceptanceBanner** in your mapping file. Below sample shows the default configuration using the default web part uploaded in the previous step.
61+
62+
```xml
63+
<WebPart Type="SharePointPnP.Modernization.PageAcceptanceBanner">
64+
<Properties>
65+
<Property Name="SourcePage" Type="string"/>
66+
<Property Name="TargetPage" Type="string"/>
67+
</Properties>
68+
<Mappings>
69+
<Mapping Default="true" Name="default">
70+
<ClientSideWebPart Type="Custom" ControlId="d462a7c4-b2e1-4e80-867a-7b46d279c161" Order="10" JsonControlData="&#123;&quot;serverProcessedContent&quot;:&#123;&quot;htmlStrings&quot;:&#123;&#125;,&quot;searchablePlainTexts&quot;:&#123;&#125;;imageSources&quot;:&#123;&#125;,&quot;links&quot;:&#123;&#125;&#125;,&quot;dataVersion&quot;:&quot;1.0&quot;,&quot;properties&quot;:&#123;&quot;description&quot;:&quot;modernizationPageDemo&quot;,&quot;sourcePage&quot;:&quot;ePage}&quot;,&quot;targetPage&quot;:&quot;{TargetPage}&quot;&#125;&#125;"/>
71+
</Mapping>
72+
</Mappings>
73+
</WebPart>
74+
```
75+
76+
> [!NOTE]
77+
> You can use your own custom banner web part by simply deploying it and then updating the mapping in the used webpartmapping.xml file.
78+
4079
### Modern site pages don't work on the site I want to transform pages in
4180

4281
By default the modern site page capability is enabled on most sites but maybe it was turned off afterwards. If that's the case the [SharePoint Modernization scanner](https://aka.ms/sppnp-modernizationscanner) will tell you which sites have turned of the modern page feature. To remediate this use below sample PnP PowerShell script:

0 commit comments

Comments
 (0)