<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to pass a token to a Timepicker? in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275208#M17414</link>
    <description>&lt;P&gt;Just in case anyone is still seeking an answer to this question. somesoni2 is partially correct. Configure your link as follows: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;......
&amp;lt;link&amp;gt;
&amp;lt;![CDATA[/app/search/seconddashboard?form.sourcetype=$click.name2$&amp;amp;form.field1.earliest=$earliest$&amp;amp;form.field1.latest=$latest$]]&amp;gt;
&amp;lt;/link&amp;gt;
......
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;In the link above the token name is the same name as the token name in the destination dashboard. In this case, it is using the default names. &lt;/P&gt;

&lt;P&gt;If you then configure your destination dashboard panels to use the Shared Time Picker (field1), the panels will load with the intended values. You should not have to change any Simple XML markup on the destination page for this to work. &lt;/P&gt;</description>
    <pubDate>Wed, 28 Mar 2018 17:35:11 GMT</pubDate>
    <dc:creator>behudelson</dc:creator>
    <dc:date>2018-03-28T17:35:11Z</dc:date>
    <item>
      <title>How to pass a token to a Timepicker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275202#M17408</link>
      <description>&lt;P&gt;Hi at all,&lt;/P&gt;

&lt;P&gt;I have to pass earliest and latest values from a form to another one by drilldown, but in the second form I have a TimePicker.&lt;/P&gt;

&lt;P&gt;I'm able to do this putting earliest and latest tokens in drilldown URL, but this works only if I directly put tokens in a search of the second form (as the following example):&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  &amp;lt;!--&amp;lt;search&amp;gt;
      &amp;lt;query&amp;gt;tag=HB ....&amp;lt;/query&amp;gt;
      &amp;lt;earliest&amp;gt;$TimeFrom$&amp;lt;/earliest&amp;gt;
      &amp;lt;latest&amp;gt;$TimeTo$&amp;lt;/latest&amp;gt;
    &amp;lt;/search&amp;gt;--&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;where &lt;CODE&gt;$TimeFrom$&lt;/CODE&gt; and &lt;CODE&gt;$TimeTo$&lt;/CODE&gt; are my tokens.&lt;/P&gt;

&lt;P&gt;But if I put these Tokens in the TimePicker (see following example):&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  &amp;lt;!--&amp;lt;input type="time" token="TimeDet" searchWhenChanged="true"&amp;gt;
    &amp;lt;label&amp;gt;&amp;lt;/label&amp;gt;
    &amp;lt;default&amp;gt;
      &amp;lt;earliest&amp;gt;$TimeFrom$&amp;lt;/earliest&amp;gt;
      &amp;lt;latest&amp;gt;$TimeTo$&amp;lt;/latest&amp;gt;
    &amp;lt;/default&amp;gt;
  &amp;lt;/input&amp;gt;--&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and I put TimeDet Tokens in the search, it doesn't work.&lt;/P&gt;

&lt;P&gt;It's like the TimePicker doesn't recognize the Tokens I passed.&lt;/P&gt;

&lt;P&gt;Anyone has an idea how to solve this problem?&lt;/P&gt;

&lt;P&gt;Thank you in advance.&lt;/P&gt;

&lt;P&gt;Bye.&lt;/P&gt;

&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Mon, 08 Feb 2016 12:58:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275202#M17408</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2016-02-08T12:58:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to pass a token to a Timepicker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275203#M17409</link>
      <description>&lt;P&gt;Try something like this&lt;/P&gt;

&lt;P&gt;On your Base Dashboard&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;......
       &amp;lt;link&amp;gt;
             &amp;lt;![CDATA[
  /app/search/seconddashboard?form.sourcetype=$click.name2$&amp;amp;form.TimeDet.earliest=$earliest$&amp;amp;form.TimeDet.latest=$latest$
]]&amp;gt;
  &amp;lt;/link&amp;gt;
        &amp;lt;/drilldown&amp;gt;
......
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;On your drilldown dashboard&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;...
 &amp;lt;input type="time" token="TimeDet"&amp;gt;
      &amp;lt;label&amp;gt;Select Time&amp;lt;/label&amp;gt;
      &amp;lt;default&amp;gt;
        &amp;lt;earliest&amp;gt;-15m&amp;lt;/earliest&amp;gt;
        &amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;
      &amp;lt;/default&amp;gt;
    &amp;lt;/input&amp;gt;
....
&amp;lt;row&amp;gt;
    &amp;lt;panel&amp;gt;
      &amp;lt;chart&amp;gt;
        &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;...Your Search....&amp;lt;/query&amp;gt;
          &amp;lt;earliest&amp;gt;$TimeDet.earliest$&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;$TimeDet.latest$&amp;lt;/latest&amp;gt;
        &amp;lt;/search&amp;gt;
......
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 08 Feb 2016 17:03:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275203#M17409</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2016-02-08T17:03:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to pass a token to a Timepicker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275204#M17410</link>
      <description>&lt;P&gt;No, in this way the second form doesn't take tokens.&lt;BR /&gt;
Thank you.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
      <pubDate>Tue, 09 Feb 2016 07:47:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275204#M17410</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2016-02-09T07:47:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to pass a token to a Timepicker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275205#M17411</link>
      <description>&lt;P&gt;Hi &lt;/P&gt;

&lt;P&gt;You must use the same token_name in each search tag &lt;BR /&gt;
look at an example: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;        &amp;lt;search&amp;gt;
           &amp;lt;query&amp;gt;...Your Search....&amp;lt;/query&amp;gt;
           &amp;lt;earliest&amp;gt;$token_name.earliest$&amp;lt;/earliest&amp;gt;
           &amp;lt;latest&amp;gt;$token_name.latest$&amp;lt;/latest&amp;gt;
         &amp;lt;/search&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 09 Feb 2016 08:35:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275205#M17411</guid>
      <dc:creator>chimell</dc:creator>
      <dc:date>2016-02-09T08:35:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to pass a token to a Timepicker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275206#M17412</link>
      <description>&lt;P&gt;Putting, as you suggested:&lt;BR /&gt;
 - "form.TimeDet.earliest=$earliest$&amp;amp;form.TimeDet.latest=$latest$" in the link of the first form&lt;BR /&gt;
 - "-15m" and "now" in the TimePicker defaults of the second form&lt;BR /&gt;
 - "$form.TimeDet.earliest$" and "$form.TimeDet.latest$" in the query default of the second form&lt;BR /&gt;
the second form take the time default of the TimePicker.&lt;BR /&gt;
In other words my form doesn't take Tokens.&lt;/P&gt;

&lt;P&gt;Instead putting "$token_name.earliest$" and "$token_name.latest$" also in the TimePicker default, panels say " Invalid earliest_time"&lt;BR /&gt;
In other words Tokens time format isn't recognized by the form.&lt;/P&gt;

&lt;P&gt;Thank you.&lt;/P&gt;

&lt;P&gt;Bye.&lt;/P&gt;

&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 08:42:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275206#M17412</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2020-09-29T08:42:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to pass a token to a Timepicker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275207#M17413</link>
      <description>&lt;P&gt;Did you ever get this solved? Or are tokens just not allowed in the time picker's earliest and latest defaults?&lt;/P&gt;</description>
      <pubDate>Wed, 17 Jan 2018 10:06:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275207#M17413</guid>
      <dc:creator>rvany</dc:creator>
      <dc:date>2018-01-17T10:06:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to pass a token to a Timepicker?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275208#M17414</link>
      <description>&lt;P&gt;Just in case anyone is still seeking an answer to this question. somesoni2 is partially correct. Configure your link as follows: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;......
&amp;lt;link&amp;gt;
&amp;lt;![CDATA[/app/search/seconddashboard?form.sourcetype=$click.name2$&amp;amp;form.field1.earliest=$earliest$&amp;amp;form.field1.latest=$latest$]]&amp;gt;
&amp;lt;/link&amp;gt;
......
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;In the link above the token name is the same name as the token name in the destination dashboard. In this case, it is using the default names. &lt;/P&gt;

&lt;P&gt;If you then configure your destination dashboard panels to use the Shared Time Picker (field1), the panels will load with the intended values. You should not have to change any Simple XML markup on the destination page for this to work. &lt;/P&gt;</description>
      <pubDate>Wed, 28 Mar 2018 17:35:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-pass-a-token-to-a-Timepicker/m-p/275208#M17414</guid>
      <dc:creator>behudelson</dc:creator>
      <dc:date>2018-03-28T17:35:11Z</dc:date>
    </item>
  </channel>
</rss>

