Updated Pages link in Wiki Pages missing



When creating a Wiki page library, every page you create/modify appears in the Updated Pages section above your quick launch navigation. Now, out of the box a team site has site pages. Site pages is a Wiki page library, and therefore it make sense just to use the Site pages as your wiki library. However, when you are using the Site Pages library, the Updated Pages link is missing.

There are lots of blog post out there showing you how to hide the Updated Pages link. Easiest way is using a bit of css :

.ms-quicklaunchouter{
 display:none;
}

.ms-core-listMenu-separatorLine{
 border-style:none;
}

However, I was struggling to find anywhere that showed you how show it. (Reversing the CSS didn’t make any difference, as the Updated Pages link wasn’t in the HTML in the first place.

Showing the Updated Pages in SitePages library.

What’s in a URL? Quite a lot it seems in this case. There must be some server side code that states, if the URL is /SitePages then don’t display Updated Pages. So the solution is to change the URL of the SitePages list. (Or don’t use the Site pages list in the first place, however, we already have content in our Site Pages list).

UPDATE: Do not do the below, if you do, when you go to “add a page”, SharePoint will ask you to create the default Wiki Library which is Site Pages. Therefore, it would be best to just create a new Wiki Library with the name you want to give, and move the existing wiki pages from Site Pages to your new Wiki Library. As long as you are on a page within the new Wiki Library, when you select “Add a Page” from the Cog, the page will be added to the Wiki Library.

There is 3 ways you could change the url.

  1. Using SharePoint designer. Find the SitePages library in the All Files section. Right click it and rename it.
  2. Using File Explorer. Find a list that you can open with Explorer (as Site Pages doesn’t allow you to) and then navigate to your site structure. Rename the Site Pages Folder. (I don’t recommend doing this way)
  3. PowerShell. I would recommend this way over the other two.
$UserName = Read-Host -Prompt "UserName"
$Password = Read-Host -Prompt "Password" -AsSecureString

$Url = "https://mysharepoint365Url.sharepoint.com/sites/TestSite"

Add-Type -Path "C:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.dll"
Add-Type -Path "C:\Program Files\Common Files\microsoft shared\Web Server Extensions\16\ISAPI\Microsoft.SharePoint.Client.Runtime.dll"

$ctx = New-Object Microsoft.SharePoint.Client.ClientContext($Url)
$ctx.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($UserName, $Password)
$ctx.ExecuteQuery();

$list = $ctx.Web.Lists.GetByTitle("Site Pages")
$list.RootFolder.MoveTo("NewLocation");
$ctx.ExecuteQuery();

write-host("Complete");

As soon as the URL has changed, the Updated Pages link will show.

NOTE: The only time it will never show up, is if you make the page your home page to your site. It doesn’t matter what the URL is, it will not show.

UPDATE: Do not move the Site Pages library, if you do, when you go to “add a page”, SharePoint will ask you to create the default Wiki Library which is Site Pages. Therefore, it would be best to just create a new Wiki Library with the name you want to give, and move the existing wiki pages from Site Pages to your new Wiki Library. As long as you are on a page within the new Wiki Library, when you select “Add a Page” from the Cog, the page will be added to the Wiki Library.
Advertisements