<?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 increase height of input text box html dashboard in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/700852#M57464</link>
    <description>&lt;P&gt;Great post!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;How do I add a submit button so that the text entered into the form gets printed after the Submit button is pressed ?&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
    <pubDate>Thu, 03 Oct 2024 07:22:37 GMT</pubDate>
    <dc:creator>tomapatan</dc:creator>
    <dc:date>2024-10-03T07:22:37Z</dc:date>
    <item>
      <title>How to increase height of input text box html dashboard?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471439#M45719</link>
      <description>&lt;P&gt;Hi, i've been banging my head against the wall for a while on this one.&lt;BR /&gt;I have an HTML dashboard that i would like users to be able to input details on particular issues. &lt;BR /&gt;These updates will generally be paragraphs of text.&lt;/P&gt;
&lt;P&gt;As such i've been trying to give the users an expanded box in which to put their details and have so far failed.&lt;BR /&gt;I've tried inline height: 500px - nothing, ive tried in an external css, width works fine (so i know it the right syntax) , but no joy.&lt;/P&gt;
&lt;P&gt;So my question is this. &lt;BR /&gt;Is there a way to make a text box have a multi line expanded input in html splunk?&lt;BR /&gt;Alternatively is there a way to use textarea and have the contents be the value of an input token?&lt;/P&gt;
&lt;P&gt;Many thanks in advance&lt;BR /&gt;Dan&lt;/P&gt;</description>
      <pubDate>Tue, 02 Aug 2022 14:28:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471439#M45719</guid>
      <dc:creator>danosoclive</dc:creator>
      <dc:date>2022-08-02T14:28:28Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471440#M45720</link>
      <description>&lt;P&gt;&lt;A href="https://stackoverflow.com/questions/17083229/how-to-change-an-input-element-to-textarea-using-jquery"&gt;https://stackoverflow.com/questions/17083229/how-to-change-an-input-element-to-textarea-using-jquery&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 20 Dec 2019 15:34:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471440#M45720</guid>
      <dc:creator>bshuler_splunk</dc:creator>
      <dc:date>2019-12-20T15:34:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471441#M45721</link>
      <description>&lt;P&gt;@danosoclive, you would need &lt;CODE&gt;&amp;lt;html&amp;gt; textarea input&lt;/CODE&gt; for this to work which is not a default input in Splunk. However if you follow the blog by @jconger, &lt;A href="https://www.splunk.com/en_us/blog/tips-and-tricks/using-html5-input-types-on-splunk-forms.html"&gt;Using HTML5 Input Types on Splunk Forms&lt;/A&gt;, you can have html input of your choice in your Splunk Form including Text Area. You would also need a companion Simple XML JS Extension file to capture the changes in the Text Area input and set/unset the required token accordingly.&lt;/P&gt;

&lt;P&gt;Following is a run anywhere example to have Multiline Text Area input like Comment in Splunk.&lt;/P&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/8121i0269E028AD0D2831/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Following is the run anywhere example Simple XML Code:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;dashboard script="html_text_area_input.js"&amp;gt;
  &amp;lt;label&amp;gt;Multi-line Text Box Area as Splunk Input using Simple XML JS Extension&amp;lt;/label&amp;gt;
  &amp;lt;init&amp;gt;
    &amp;lt;set token="tokComment"&amp;gt;Not Applicable.&amp;lt;/set&amp;gt;
  &amp;lt;/init&amp;gt;
  &amp;lt;row&amp;gt;
    &amp;lt;panel&amp;gt;
      &amp;lt;html&amp;gt;
        &amp;lt;style&amp;gt;
          #html_ta_user_comment{
            width: 500px;
            height: 115px;            
          }
        &amp;lt;/style&amp;gt;
        &amp;lt;div&amp;gt;
          &amp;lt;label&amp;gt;Enter Comment&amp;lt;/label&amp;gt;
        &amp;lt;/div&amp;gt;
        &amp;lt;div&amp;gt;
          &amp;lt;textarea id="html_ta_user_comment" name="comment" rows="10" cols="30"&amp;gt;Not Applicable.&amp;lt;/textarea&amp;gt;
        &amp;lt;/div&amp;gt;
      &amp;lt;/html&amp;gt;
      &amp;lt;table&amp;gt;
        &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;| makeresults
| fields - _time
| eval "Text Entered"=$tokComment|s$&amp;lt;/query&amp;gt;
          &amp;lt;earliest&amp;gt;-24h@h&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;
          &amp;lt;sampleRatio&amp;gt;1&amp;lt;/sampleRatio&amp;gt;
        &amp;lt;/search&amp;gt;
        &amp;lt;option name="count"&amp;gt;20&amp;lt;/option&amp;gt;
        &amp;lt;option name="dataOverlayMode"&amp;gt;none&amp;lt;/option&amp;gt;
        &amp;lt;option name="drilldown"&amp;gt;none&amp;lt;/option&amp;gt;
        &amp;lt;option name="percentagesRow"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="refresh.display"&amp;gt;progressbar&amp;lt;/option&amp;gt;
        &amp;lt;option name="rowNumbers"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="totalsRow"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="wrap"&amp;gt;true&amp;lt;/option&amp;gt;
      &amp;lt;/table&amp;gt;
    &amp;lt;/panel&amp;gt;
  &amp;lt;/row&amp;gt;
&amp;lt;/dashboard&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Following is the Simple XML JS Extension file &lt;CODE&gt;html_text_area_input.js&lt;/CODE&gt; to be placed under Splunk app's appserver/static folder (may require debug refresh, bump or splunk restart along with internet browser history cleanup).&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;require(["jquery", 
        "splunkjs/mvc", 
        "splunkjs/mvc/simplexml/ready!"], 
    function($, mvc) {
    var defaultTokenModel = mvc.Components.get("default");
    var submitTokenModel = mvc.Components.get("submitted");
    $(document).on("change","#html_ta_user_comment",function(){
        var strComment=$(this).val();
        var strTokComment=defaultTokenModel.get("tokComment");
        if(strComment!=="" &amp;amp;&amp;amp; strComment!==undefined){
            if(strTokComment!==undefined || strTokComment!==strComment){
                defaultTokenModel.set("tokComment",strComment);
                submitTokenModel.set("tokComment",strComment);
            }
        }else{
            defaultTokenModel.unset("tokComment");
            submitTokenModel.unset("tokComment");
        }
    });
});
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 21 Dec 2019 11:23:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471441#M45721</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2019-12-21T11:23:48Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471442#M45722</link>
      <description>&lt;P&gt;Hi niketnilay,&lt;/P&gt;

&lt;P&gt;Thankyou for your comprehensive response.&lt;BR /&gt;
However I cannot seem to get the above to work at all.&lt;BR /&gt;
I can now define a text area and have initialised the token but it will not update the token 'on("change")' when I type something in, or at least it does not show me that it has changed.  Any idea what could be going wrong?!&lt;/P&gt;

&lt;P&gt;Thanks&lt;BR /&gt;
Dan&lt;/P&gt;</description>
      <pubDate>Mon, 06 Jan 2020 12:58:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471442#M45722</guid>
      <dc:creator>DanoSOC</dc:creator>
      <dc:date>2020-01-06T12:58:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471443#M45723</link>
      <description>&lt;P&gt;A bit of jiggery pokery later and I managed to make it work, and have successfully implemented into a HTML dashboard.  Thanks for your help neketnilay !&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jan 2020 13:08:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/471443#M45723</guid>
      <dc:creator>DanoSOC</dc:creator>
      <dc:date>2020-01-08T13:08:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/530370#M45724</link>
      <description>&lt;P&gt;Can you please tell me how&amp;nbsp; you made it "change "?&lt;/P&gt;</description>
      <pubDate>Mon, 23 Nov 2020 05:34:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/530370#M45724</guid>
      <dc:creator>j_cabanillas</dc:creator>
      <dc:date>2020-11-23T05:34:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/574313#M47115</link>
      <description>&lt;P&gt;Can you be more specific about what you changed?&lt;/P&gt;</description>
      <pubDate>Wed, 10 Nov 2021 03:01:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/574313#M47115</guid>
      <dc:creator>emottola</dc:creator>
      <dc:date>2021-11-10T03:01:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/607886#M49873</link>
      <description>&lt;P&gt;Hi, your solution worked perfectly. I have another question, how can I transfer value from another dashboard back to the "tokcomment" token?&lt;/P&gt;</description>
      <pubDate>Tue, 02 Aug 2022 08:28:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/607886#M49873</guid>
      <dc:creator>klchoy</dc:creator>
      <dc:date>2022-08-02T08:28:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/700852#M57464</link>
      <description>&lt;P&gt;Great post!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;How do I add a submit button so that the text entered into the form gets printed after the Submit button is pressed ?&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Oct 2024 07:22:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/700852#M57464</guid>
      <dc:creator>tomapatan</dc:creator>
      <dc:date>2024-10-03T07:22:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/700856#M57465</link>
      <description>&lt;P&gt;Off topic but you could look at the documentation&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.splunk.com/Documentation/Splunk/9.0.4/DashStudio/inputConfig#Add_a_submit_button" target="_blank"&gt;https://docs.splunk.com/Documentation/Splunk/9.0.4/DashStudio/inputConfig#Add_a_submit_button&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Oct 2024 08:04:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/700856#M57465</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2024-10-03T08:04:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to increase height of input text box html dashboard</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/700863#M57466</link>
      <description>&lt;P&gt;Answered my own question - the script below worked for me:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;require([
'splunkjs/mvc',
'splunkjs/mvc/simplexml/ready!'
], function(mvc) {
console.log('JavaScript loaded'); // Debug log to confirm script is running

var defaultTokenModel = mvc.Components.getInstance('default');
var submittedTokens = mvc.Components.getInstance('submitted');

document.getElementById('submit_button').addEventListener('click', function() {
var comment = document.getElementById('html_ta_user_comment').value;
console.log('Submit button clicked'); // Debug log to confirm button click
console.log('Comment:', comment); // Debug log to show the comment value
defaultTokenModel.set('tokComment', comment);
console.log('Token set:', defaultTokenModel.get('tokComment')); // Debug log to confirm token is set

// Trigger the search by updating the submitted tokens
submittedTokens.set(defaultTokenModel.toJSON());
});
});&lt;/LI-CODE&gt;
&lt;P&gt;By adding the line submittedTokens.set(defaultTokenModel.toJSON());, we ensured that the search is refreshed whenever the token value changes.&lt;/P&gt;</description>
      <pubDate>Thu, 03 Oct 2024 14:13:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-increase-height-of-input-text-box-html-dashboard/m-p/700863#M57466</guid>
      <dc:creator>tomapatan</dc:creator>
      <dc:date>2024-10-03T14:13:49Z</dc:date>
    </item>
  </channel>
</rss>

