Recent

Moving Key Filters to top of left navigation

By default, Key Filters display below all the left navigation links.  If the site has a really long left navigation, you might need to change the App views to make the Key Filter display above the left navigation links instead.  If you need instructions on how to add Key Filters to lists or libraries, please first read the Key Filter tutorial.
Move-Key-Filter-Top-16-0

 

Changing Key Filters to display first

Use the instructions below to edit the current view of the App to make the Key Filters appear at the top of the page instead of at the bottom of the left navigation.  Please note that these steps will have to be applied to all existing views, All new views created after this change will have the script editor already added to them though.

1. Go to the App View you want to change, click on Site Settings > Edit page
Move-Key-Filter-Top-16-1

2. On the App view page in edit mode, click on the Add a Web Part option.
Move-Key-Filter-Top-16-2

3. Scroll down the Categories and find Media and Content, select Script Editor, click the Add button.
Move-Key-Filter-Top-16-3

4.  Hover over the Script Editor webpart, click on the dropdown arrow, select Edit Web Part.
Promoted-Links-Vertical-16-3

5.  Now a Edit Snippet option should appear, click it.
Promoted-Links-Vertical-16-4

6. Paste in the following script to the Script Editor webpart:

//Moves Key Filter Element to top of Quick Launch or Left Navigation
var fragment = document.createDocumentFragment();
fragment.appendChild(document.getElementById(‘ctl00_PlaceHolderLeftNavBar_QuickLaunchNavigationManager’));
document.getElementById(‘idKeyFiltersContainer’).appendChild(fragment);

<style>
/* Fixes the Margin for the Key filter so it’s aligned with left nav links */
#ctl00_PlaceHolderLeftNavBar_QuickLaunchNavigationManager {
margin-left: -20px;
margin-top:20px;
}
</style>

Move-Key-Filter-Top-16-6

7. After the script has been entered, click the Stop Editing option for the page.
Move-Key-Filter-Top-16-7

Completed Example: Now on that view for the App, the Key Filter options will display above the left navigation.
Move-Key-Filter-Top-16-8

About Nick Hurst (84 Articles)
SharePoint and Nintex developer who strives to find easy to deploy and maintain solutions for business problems.

3 Comments on Moving Key Filters to top of left navigation

  1. I want Key Filters at the bottom, but there is too much white space between it and the folder above it in the leftnav bar. How do I close up this space? Thanks. (FYI, I am not a developer. 🙂 )

    Like

  2. I found the solution. Thanks.

    Like

  3. for those who are wondering if the script is not working, add language attribute to the script and it will work.

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: