Is there a way to set a default value for my Metadata Navigation and Filtering's Key Filters fields
-
06-01-2021 - |
Question
I have a wiki pages library inside my SP on-premises 2013. And I have enabled the "Metadata Navigation and Filtering" site feature. Then i went to my pages library setting >> Metadata navigation settings >> and i added 5 site columns which are of type Managed Metadata inside the "Configure Key Filters", as follow:-
here is the result
now i am trying to find a way to define default values for these key filters. i tried setting a defualt value for these site columns, but the defualt value will be shown when creating a new page, but will not have any effect on the key filter.. so is there a way to set a defualt value for my key filters??
Solution
If you want to filter a value by default, I'd probably use the query strings as a default page link (for navigation or webpart header link) like this: [...]/doclibrary/Forms/AllItems.aspx?FilterField1=Doc%5Fx0020%5FStatus&FilterValue1=Archived
and add more filters with FilterField2
and FilterValue2
Or if you are looking to add values to the textboxes, I'd use javascript on load to add whatever values you want to put.