I am creating a splunk dashboard with a few reports.
On one report (outputted as a table), I want a long url to be replaced by a short number.
When clicking that number (VIA THE PDF DASHBOARD REPORT) , I want it to go to the external url.
Placing just the url works, but it's broken cause it's to long and wont open the full URL.
I followed the following guide:
It works while viewing the dashboard in a browser except for I still don't know how to edit the link correctly.
<row> <panel> <html> <style> </style> </html> <table> <title>Report</title> <search ref="Report"></search> <fields>Name, QueueTime, FinishTime, Result, BuildId</fields> <option name="count">10</option> <option name="drilldown">cell</option> <drilldown target="_blank"> <condition field="BuildId"> <link target="_blank"> $row.URL$ # Not working . URL is the name of the filed with the long url that I want replaced by another field with a short number https://google.com # Works </link> </condition> </drilldown> </table> </panel> </row>
index="reports" | where (source LIKE "%Report%") | eval BuildId = Id + "" | table Name, QueueTime, FinishTime, Result
If I just add the URL itself in a table, the link is clickable in the PDF, but it's to long and the browser will only open what hasn't went to the second line. The URL field itself is correct
So if I gave you a custom search command that uses bit.ly service to shorten urls, would you be interested knowing that it’s giving bit.ly all your links but providing the short url and also statistics on their usage?
It would work like this
... | bitly urlfield=fieldWithLongURLs | eval url = bitly_output | table url ...
A powershell script gets the info and sends an html email and also sends this info into splunk. The html email's link works and looking at the dashboard in splunk on a browser, the link works.