Splunk Search

How to modify/resize my table column widh based on its contents using CSS ?

Upas02
Path Finder

HI,
I am using a table command to print out _time, application, name and events generated by that application using table command.
The problem is events are long and it is crossing the page, need to first scroll down and then scroll horizontally to see the events, which is very cumbersome.
I want the table column to auto resize itself based on the content. I have tried changing table width and wordwrap in CSS, read all related answers, nothing seems to work.
I am new to CSS, below are the code snippets I tried.
Any help would be much appreciated.

 .table td {          
      word-wrap: break-word;
      width: 300px;
  }

another way I tried -
.table tr td {

width: 70%;
}

0 Karma
Get Updates on the Splunk Community!

Pro Tips for First-Time .conf Attendees: Advice from SplunkTrust

Heading to your first .Conf? You’re in for an unforgettable ride — learning, networking, swag collecting, ...

Raise Your Skills at the .conf25 Builder Bar: Your Splunk Developer Destination

Calling all Splunk developers, custom SPL builders, dashboarders, and Splunkbase app creators – the Builder ...

Hunt Smarter, Not Harder: Discover New SPL “Recipes” in Our Threat Hunting Webinar

Are you ready to take your threat hunting skills to the next level? As Splunk community members, you know the ...