<?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: Align the first column of the table in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207228#M60435</link>
    <description>&lt;P&gt;@niketnilay Thanks for answering, you are perfectly correct!&lt;/P&gt;</description>
    <pubDate>Sat, 25 Nov 2017 16:29:56 GMT</pubDate>
    <dc:creator>ashish9433</dc:creator>
    <dc:date>2017-11-25T16:29:56Z</dc:date>
    <item>
      <title>Align the first column of the table</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207224#M60431</link>
      <description>&lt;P&gt;Hi Team,&lt;/P&gt;

&lt;P&gt;I have a table in the dashboard, wherein i want first column to be left aligned and rest all the columns to be center aligned as shown in the below image. &lt;/P&gt;

&lt;P&gt;I want column Field1 all its data to be left aligned whereas other field(2-6) and its data to be center aligned. I used custom CSS as below.  &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;#table1 .table-chrome.table-striped&amp;gt;tbody&amp;gt;tr.odd&amp;gt;td {
    text-align: center!important;
}

#table1 .table-chrome.table-striped&amp;gt;tbody&amp;gt;tr.even&amp;gt;td {
    text-align: center!important;
}
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Using the above CSS all the columns are center aligned now and i am unable to find the CSS to just align the first column to left.&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/1467i6C7D39E092905494/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;Can any one please guide me how do i left align first column and center align others in the table in a dashboard on Splunk?&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jun 2016 10:20:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207224#M60431</guid>
      <dc:creator>ashish9433</dc:creator>
      <dc:date>2016-06-13T10:20:59Z</dc:date>
    </item>
    <item>
      <title>Re: Align the first column of the table</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207225#M60432</link>
      <description>&lt;P&gt;I am able to solve the issue by my self, adding the answer here so that incase anyone else faces a similar requirement.&lt;/P&gt;

&lt;P&gt;I did this by just adding the following custom CSS for the respective table.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;#table1 .table th, .table td {
    text-align: center!important;
}

#table1 .table td:first-child {
    text-align: left!important;
}
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 14 Jun 2016 09:55:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207225#M60432</guid>
      <dc:creator>ashish9433</dc:creator>
      <dc:date>2016-06-14T09:55:44Z</dc:date>
    </item>
    <item>
      <title>Re: Align the first column of the table</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207226#M60433</link>
      <description>&lt;P&gt;Hi @ashish9433&lt;BR /&gt;
which is your table name or reference to the table here  ?&lt;/P&gt;

&lt;P&gt;If i want to do it for all the tables then is there any specific code which i can just put in my .css file. &lt;/P&gt;</description>
      <pubDate>Sat, 25 Nov 2017 08:14:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207226#M60433</guid>
      <dc:creator>surekhasplunk</dc:creator>
      <dc:date>2017-11-25T08:14:49Z</dc:date>
    </item>
    <item>
      <title>Re: Align the first column of the table</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207227#M60434</link>
      <description>&lt;P&gt;@surekhasplunk, &lt;CODE&gt;table1&lt;/CODE&gt; would be the table &lt;CODE&gt;id&lt;/CODE&gt; set in Simple XML Dashboard code.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;table id="table1"&amp;gt;
     ....
&amp;lt;/table&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;If you want to apply this for all tables you just need to take out &lt;CODE&gt;#table1&lt;/CODE&gt; from the CSS style code.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;.table th, .table td {
     text-align: center!important;
 }
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Just FYI, you should also know that whether text is left-aligned or right-aligned depends on whether the data entered is numeric or string i.e. for &lt;CODE&gt;class="string"&lt;/CODE&gt; default &lt;CODE&gt;left align&lt;/CODE&gt; and for &lt;CODE&gt;class="numeric"&lt;/CODE&gt; right align:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;td.numeric, th.numeric {
    text-align: right;
}
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 25 Nov 2017 16:21:36 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207227#M60434</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2017-11-25T16:21:36Z</dc:date>
    </item>
    <item>
      <title>Re: Align the first column of the table</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207228#M60435</link>
      <description>&lt;P&gt;@niketnilay Thanks for answering, you are perfectly correct!&lt;/P&gt;</description>
      <pubDate>Sat, 25 Nov 2017 16:29:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Align-the-first-column-of-the-table/m-p/207228#M60435</guid>
      <dc:creator>ashish9433</dc:creator>
      <dc:date>2017-11-25T16:29:56Z</dc:date>
    </item>
  </channel>
</rss>

