Changing Hyperlink States using CSS Styles
In the report designer, it is easy to change common text styles to suit your chosen color scheme. However, changing hyperlinks states from the blue and purple used in the standard OMS reports is not as straight forward.
If you want to change the different states of a hyperlink, there is a workaround that allows you to do this by embedding CSS styles into a report header. This is an easy solution to the problem and can also be used for other purposes.
Create a Link Style Component
First create a new component style in the Style Designer called Link:
1. Open the Latest Human Sessions report.
2. Open the Style Designer.
3. Create a new component style called Link.
4. Set a different Text Brush color property that contrasts with other text used in this report, and then close the designer.
5. In the Latest Human Sessions report click on the text links that you want to change. If you want to select multiple links, hold down the SHIFT key while you make the selection.
6. Format these links by selecting the Link style in the Style panel.
7. In the ribbon, click Save.
Create a CSS Style
1. In the Latest Human Sessions report, drag a text box from the toolbox to the report header.
2. Double click on the text box to open the Expression Editor.
3. Copy the following CSS code into the Expression Editor:
{"<style type='text/css'>a { color:green } a:visited { color:red }</style>"}
Now every link formatted with the Link style will have the styles contained in this expression applied to them.
4. With the same text box selected, in the Properties panel set the Allow Html tags property to False.
If you do not set this property the changes you made to the hyperlink states may not be visible in the report.
5. In the ribbon, click Save and preview the report.
If you want to remove the underline state from a hyperlink:
1. Open the Expression Editor
2. Add the following expression:
a { text-decoration:none }
3. Save your report and preview your new link states in Sitecore Analytics.