Dashboards & Visualizations

How to hide all form input filters in a dashboard by default?

lakromani
Builder

In dashboard, if you add input, you will see a text Hide Filters.
I would like all the filters to be hidden in one dashboard by default.
The users need to click Show Filters.

Searching around and did not find anything.

alt text

1 Solution

sundareshr
Legend

Try editing your nav links to include a querystring with hideFilters=True

http://dev.splunk.com/view/webframework-developapps/SP-CAAAEP9

View solution in original post

marcoscala
Builder

You have to modify the source:

<form hideFilters="true">
...

This will work even with a default dashboard where you cannot modify the query string.

Marco

sundareshr
Legend

Try editing your nav links to include a querystring with hideFilters=True

http://dev.splunk.com/view/webframework-developapps/SP-CAAAEP9

datasearchninja
Communicator

I downvoted this post because the other answer on this page is more correct

0 Karma

lakromani
Builder

Did not work.

True also need to be quoted, so it should be some like this:

hidefilters='true'
hideFilters='true'
hideFilters='True'
0 Karma

evinasco
Communicator

Can I eliminate "Hide Filters" text from dashboard?

0 Karma

rjthibod
Champion

With CSS you can. Here is the CSS you need to add to a file in your app.

/* hide global input hiding button in 6.5+ */
a.hide-global-filters {
  display: none !important;
}

Alternatively, you can put this in a hidden row in the dashboard.

<row depends="$hiddenCSS$">
  <html>
    <style>
      a.hide-global-filters {
        display: none !important;
      }
    </style>
  </html>
</row>

evinasco
Communicator

Thanks, it worked !!!

0 Karma

rjthibod
Champion

Glad to hear it. You can upvote/like my comment to show that it helped.

rjthibod
Champion

Would it easier or cleaner to put it on top of the XML in the dashboard or form like the similar options listed here: http://docs.splunk.com/Documentation/Splunk/6.5.0/Viz/PanelreferenceforSimplifiedXML?

0 Karma

lakromani
Builder

Thanks it worked there:

0 Karma

saurabh009
Path Finder

I am also looking for similar solution. What you have added and where?

0 Karma

lakromani
Builder

Normal a dashboard starts like this:
<form>
Change it to:
<form hideFilters="true">
And you are done

saurabh009
Path Finder

Is it possible to remove hideFilters or showFilters link completely and show all the filters as default?
I am not able to remove them after upgrading Splunk to 6.5.2.

0 Karma

lakromani
Builder

Dont know. If some works with one version and not with other, make a support case.

0 Karma

saurabh009
Path Finder

Thanks, I will.

0 Karma

rmarcum
Explorer

My approach has been to put all of the filters in a panel at the top of the dashboard with no chart, table, etc. code in it (see below), then have a filter on the dashboard that does a Hide/Show on the panel. Unless there is at least one filter in the panel, Splunk will discard the panel. So, start with this, add some filters, then discard this filter.

<panel>
  <title>XXXX User Input Filters</title>
  <input type="multiselect" token="YYYY" searchWhenChanged="true">
    <label>Select XXXX </label>
    <choice value="*">All </choice>
    <choice value="A">First</choice>
    <choice value="B">Second</choice>
    <choice value="C">Third</choice>
    <default>A,C </default>
    <valuePrefix>MyField="</valuePrefix>
    <valueSuffix>"</valueSuffix>
    <delimiter> OR </delimiter>
  </input>
</panel>
0 Karma
Get Updates on the Splunk Community!

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...

What’s New in Splunk Security Essentials 3.8.0?

Splunk Security Essentials (SSE) is an app that can amplify the power of your existing Splunk Cloud Platform, ...