In this article, we’ll show how to easily create a clickable snippet in a dashboard. Our snippet will show a number of customers in Customers table and clicking anywhere in the code snippet area will take us to the Customers table in question.
1. Add a code snippet to the dashboard. Use the following code. This is just a sample code and you can replace it with any code you want.
PHP
C#
2. Create and run your application. Go to the dashboard page, right-click on this snippet and choose “Inspect”. What we’re looking for is an identifier of the DIV that contains our code snippet. In our case, it will be dashelement_cloudflare_snippet1.
3. Add the following code to the dashboard: Javascript OnLoad event. Here we use the ID of the div we just found.
That’s it. Appreciate!