Dashboards & Visualizations

Looking for a way to append a token value to the end of a URL

ArmbrusterC
Explorer

I have a dashboard with a field called %field1%
I would like to generate a simple hyperlink the user can click on to open a new tab to our ticketing system.
I need to append the value of the token to the end of a static URL. Then display that value as an active link somewhere in the dashboard for the user to click and open the ticketing system.

For example:
If I enter FooBar in the field

The link would be:
hxxps://ticketing.system.com/textsearch.do?sysparm_search=FooBar

Thanks in advance for any help. I will continue reading and update the question myself if I find a working solution. This seems too simple not to be possible.

0 Karma
1 Solution

sundareshr
Legend

That depends on what type of field it is. Can you share your dashboard code. In most cases. a token value can be reference by $tokenname$. So in your example, it could be as simple as

<link>hxxps://ticketing.system.com/textsearch.do?sysparm_search=$tokenname$</link>

There a wealth of information here: http://docs.splunk.com/Documentation/Splunk/6.4.1/Viz/tokens

View solution in original post

sundareshr
Legend

That depends on what type of field it is. Can you share your dashboard code. In most cases. a token value can be reference by $tokenname$. So in your example, it could be as simple as

<link>hxxps://ticketing.system.com/textsearch.do?sysparm_search=$tokenname$</link>

There a wealth of information here: http://docs.splunk.com/Documentation/Splunk/6.4.1/Viz/tokens

ArmbrusterC
Explorer

This put me on the right track. The field is a text input for a hostname.
I have posted the correct answer below.

<row>
    <html> <a href="https://ticketing.system.com/textsearch.do?sysparm_search=$field1$">Search for Tickets</a> </html>
</row>
Get Updates on the Splunk Community!

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...

What’s New in Splunk Security Essentials 3.8.0?

Splunk Security Essentials (SSE) is an app that can amplify the power of your existing Splunk Cloud Platform, ...

Let’s Get You Certified – Vegas-Style at .conf24

Are you ready to level up your Splunk game? Then, let’s get you certified live at .conf24 – our annual user ...