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!

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...

New in Observability Cloud - Explicit Bucket Histograms

Splunk introduces native support for histograms as a metric data type within Observability Cloud with Explicit ...