Aug 19 2020 09:54 AM
Aug 19 2020 09:54 AM
I am migrating several sites from sharepoint on-premises to sharepoint online, however in some document libraries I have different types of documents (docx, pdf, xlsx...) with urls to old sites in sharepoint on-premises.
I am search for a solution, but until now seems that only with a third party tool I can do that. For example, Cognillo is a nice tool but very expensive.
My question is if it there is a solution provided by microsoft to solve this, for example any kind of powershell script or if there is another third party tool to solve this problem?
Aug 19 2020 10:18 AM
Let's start by ruling out the obvious. How are you migrating? It's possible that your current tool may have something that can do this for you.
Aug 19 2020 10:52 PM
Aug 20 2020 12:33 AM
@Steven Andrews unfortunately not. I am using Sharegate and at this moment doesn't have this feature. I checked it.
Aug 20 2020 04:54 AM
You basically have 2 problems:
a. migrated documents that contain links that are broken because of the migration
b. links from external places (emails, bookmarks, documents in other systems, ...) that refer to the old SharePoint location.
Addressing problem a is not extremely hard. Use tools to replace the links within the migrated documents. It may cost some $'s but you will get an acceptabel result. Do check if the 3rd tools also change the modify date. If that has been retained as part of the migration you do not want to change these dates when fixing the links. I am not aware of PS scripts with this capability.
Problem b is much more challenging. These links will persist for years to come. One way to overcome this is by migrating documents plus their original url's to the new SharePoint system and then make the original url's searchable. Also automatically redirect traffic to the old locations to the search page.
(Interesting topic though. Something to give proper priority in our roadmap.)
Aug 20 2020 08:33 AM
According our organization, problem a) is the most relevant. We have many official documents with link to other documents or folders, and we must to update this links.
It will be good with the improvement of Microsoft migration tool this feature should also be included.
Aug 20 2020 08:47 AM
Inspired by the code found here, here and here, I created this file in C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\CONTROLTEMPLATES\WikiMiniConsole.ascx
<%@ Control Language="C#" AutoEventWireup="false" %>
<%@Assembly Name="Microsoft.SharePoint, Version=18.104.22.168, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@Register TagPrefix="SharePoint" Assembly="Microsoft.SharePoint, Version=22.214.171.124, Culture=neutral, PublicKeyToken=71e9bce111e9429c" namespace="Microsoft.SharePoint.WebControls"%>
<%@Register TagPrefix="SPHttpUtility" Assembly="Microsoft.SharePoint, Version=126.96.36.199, Culture=neutral, PublicKeyToken=71e9bce111e9429c" namespace="Microsoft.SharePoint.Utilities"%>
<%@ Register TagPrefix="wssuc" TagName="ToolBar" src="~/_controltemplates/ToolBar.ascx" %>
<%@ Register TagPrefix="wssuc" TagName="ToolBarButton" src="~/_controltemplates/ToolBarButton.ascx" %>
<SharePoint:RenderingTemplate ID="WikiMiniConsole" runat="server">
<table id="miniconsole" cellspacing="0" cellpadding="0" border="0" width="100%"><tr><td>
<table class="ms-wikieditsecond" cellspacing="0" cellpadding="0" border="0" width="100%"><tr><td>
<table class="ms-wikieditthird" cellspacing="0" cellpadding="0" border="0" width="100%"><tr><td>
<!-- this is for the orange cast inside the menu -->
<table class="ms-wikieditorange" cellspacing="0" cellpadding="0" border="0" width="100%">
<td class="ms-wikieditorangeinnera" style=";width:100%;"> </td>
<wssuc:ToolBar CssClass="ms-wikitoolbar" runat="server">
<SharePoint:WikiEditItemButton Text= "<%$Resources:wss,siteactions_wikieditpage%>" runat="server"/>
<SharePoint:WikiPageHistoryButton Text= "<%$Resources:wss,siteactions_viewpagehistory%>" ButtonID="WikiPageHistory" runat="server"/>
<SharePoint:WikiIncomingLinksButton Text= "Incoming Links" ButtonID="WikiIncomingLinks" runat="server"/>
var toc = "<div id='toc' style='background:#EBF3FF;"
+"border:1px solid #6F9DD9;display:none;"
//get the url for the incoming links page
u = $("a[id$=WikiIncomingLinks_LinkText]").href;
//get the target container and load it with the incoming links
//filtered to show the links list only
$("#toc").load(u + " .ms-propertysheet");
$("#toc a").wrap("<li style='padding:0;margin:0;'></li>");
$("#toc li").prepend("<img style='margin-right:5px;' alt='' src='/_layouts/images/square.gif'/>");
// override the target of our hyperlink to bring up the menu
I hope this helps you with broken links on Sharepoint online migration.
Nov 11 2020 12:47 AM
I need to regularly check my sites for dead links within SharePoint Online. I created my tool and decided to share it. https://blog.p-difm.com/sharepoint-online-check-for-broken-links/
Glad if it helps
Dec 25 2020 02:19 AM
@Andre_SilvaThere are also other tools doing the same job like Cognillo that you mentioned but are more affordable.
My tool is ReplaceMagic (www.replacemagic.com) where identification of links in documents, SharePoint pages (hard coded links, Wiki or Canvas pages), list item field of URL type and coming Web Parts is free. In case that you want to fix links that is chargeable but ReplaceMagic licenses does not have limitations on number of sites or documents or link except to number of users/computers where tool is used. Also RM licenses are perpetual.
Of course, we can keep document metadata (last modified date or last modified by).
At the end, I doubt that with scripts you'll be able to come to functionality that is provided by tools similar to ReplaceMagic.