- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
08-21-2023 05:01 AM
Hello,
We use markdown tables to show the analysts' incident data. We use them for manual tasks in details as in layouts. We'd like to paint those cells where the data shown is critical. For example, on a markdown table where some hashes are detonated, we'd like to paint the rows or cells where hashes are malicious.
08-21-2023 04:41 PM
Hi @Josep – Background color can be added in markdown using the following syntax:
{{background:#<HEX_COLOR>}}(<TEXT>)
E.g. for red:
{{background:#fd0800}}(<TEXT>)
Alternatively, you can also use HTML for your General Purpose Dynamic Section tables.
For markdown, use the markdown editor on the XSOAR CLI to see what other formatting options are available.
08-23-2023 06:19 PM
@Josep I'd suggest using HTML instead for greater flexibility. Simple example that would work for a General Purpose Dynamic Section in the layout:
html = """
<table border="1x solid black">
<tr>
<th>Col 1</th>
<th>Col 2</th>
</tr>
<tr>
<td style="background-color:#FF1744">1a</td>
<td>2a</td>
</tr>
<tr>
<td style="background-color:#00CD33">1b</td>
<td>2b</td>
</tr>
</table>
"""
return_results({
'ContentsFormat': EntryFormat.HTML,
'Type': EntryType.NOTE,
'Contents': html
})
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!