Splunk Search

How to remove "Date & Time Range" from time picker using HTML code?

bhavlik
Path Finder

I have a time picker in one of my dashboards and want the time picker to only display "Date Range".  I have been successful in writing HTML code to remove all the other ones but cannot figure out how to get "Date & Time Range" to be removed as well.  

Here is the code I have currently:

 

 

 

<html>
      <style>
         div[data-test-panel-id="presets"] {
             display: none;
         }
         div[data-test-panel-id="relative"] {
             display: none;
         }
         div[data-test-panel-id="dateandtimerange"] {
             display: none;
         }
         div[data-test-panel-id="realTime"] {
             display: none;
         }
         div[data-test-panel-id="advanced"] {
             display: none;
         }
      </style>
    </html>

 

 

 

I am assuming my name for "Date & Time Range" is incorrect but no clue as to how it should be written.  Does anyone know what the panel id for that is?

Labels (1)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust
         div[data-test-panel-id="dateTime"] {
             display: none;
         }

Open the timepicker then inspect the html - you can find the panel ids there

ITWhisperer_0-1605870282176.png

 

View solution in original post

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust
         div[data-test-panel-id="dateTime"] {
             display: none;
         }

Open the timepicker then inspect the html - you can find the panel ids there

ITWhisperer_0-1605870282176.png

 

0 Karma

RanjiRaje
Explorer

Was searching for this for past 2 days. thanks for the post.

0 Karma

bhavlik
Path Finder

Thank you!

0 Karma
Get Updates on the Splunk Community!

There's No Place Like Chrome and the Splunk Platform

Watch On DemandMalware. Risky Extensions. Data Exfiltration. End-users are increasingly reliant on browsers to ...

The Great Resilience Quest: 5th Leaderboard Update

The fifth leaderboard update for The Great Resilience Quest is out &gt;&gt; &#x1f3c6; Check out the ...

Devesh Logendran, Splunk, and the Singapore Cyber Conquest

At this year’s Splunk University, I had the privilege of chatting with Devesh Logendran, one of the winners in ...