Manage SharePoint using bookmarklets

Modern SharePoint is great and includes a lot of new functionalities that I love but at the same time it changed the location of some links that were one click away on classic SharePoint.

In this article I’m sharing some of the bookmarklets that I use daily to get things done faster and to save a few clicks.

A bookmarklet is nothing more than a bookmark that contains JavaScript, it adds functionality to the browser, such as modifying a web page.

If you want to take advantage of this functionality that is available in all modern browsers copy the examples bellow and add them to the bookmarks of your browser.

Modern SharePoint

Open Site Settings

On modern SharePoint the site settings is hidden inside the site information menu, this requires an extra click to open a page that use to be available in the settings menu, to avoid it you can use the bookmarklet bellow. It works for modern and classic SharePoint from any page context.

javascript:(function(){var url = document.location.href.split('/Pages')[0].split('/SitePages')[0].split('/_layouts')[0];if(url.endsWith('.aspx')){url = url.replace(new RegExp('\/[a-z A-Z 0-1 \- _]*.aspx'),'')}location.replace(url+"/_layouts/15/settings.aspx")}());

Open Page in Maintenance Mode

This page is extremely handy when you are debugging your own web parts on SharePoint.

javascript:(function(){location.replace(window.location.href+"?maintenancemode=true")})();

Go to Classic

Modern lists and libraries are awesome, but they don’t have yet all the functionalities available in the classic environment, use the bookmarklet below to modify the cookie that tells SharePoint what mode should be used.

javascript:(function(){document.cookie="splnu=0;domain="+window.location.hostname+";"; location.href=location.href;})();

Classic SharePoint

Open Web Part Manager

This page helps you to manage the web parts in the classic SharePoint and is extremely handy when you need to remove faulty web parts from the page.

javascript:(function(){location.replace(window.location.href+"?contents=1")})();

Go to Modern

The link to go to modern is not always visible, if you are using the Oslo master page our are using a custom master page you will lose the default SharePoint like, if you find yourself in this scenario use this bookmarklet to go to modern SharePoint.

javascript:(function(){document.cookie="splnu=1;domain="+window.location.hostname+";"; location.href= location.href})();

Classic and Modern SharePoint

Filter Lists and Libraries

Lists and Libraries in modern and classic SharePoint include a functionality to filter the content however it only works for columns that belong to the view. If you want to filter using hidden columns use the bookmarklet bellow, it will prompt for the name of the column and for the value. See it in action in the link below.

javascript:(function(){var listView=document.location.href;var fieldName=prompt("Please enter the field name", "");var fieldValue=prompt("Please enter the field value", "");document.location.href=listView+"?FilterField1="+fieldName.replace(/ /g, '_x0020_')+"&FilterValue1="+fieldValue;})();

Technology vector created by rawpixel.com – www.freepik.com


One Response to “Manage SharePoint using bookmarklets”

  1. David Ramalho

    April 11, 2019

    Nice to have. Thanks.

    Reply

Leave a Reply


Web developer focused on SharePoint branding, blogger, tech enthusiast. Travelling and sports are my addictions, knowledge and success are my daily motivations.