Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ## First, add the following function to the page's <head> section:
- <script type="text/javascript">
- function recordCustomAndEvent(link, category, action, label, index, name, value, scope) {
- _gat._getTrackerByName()._trackEvent(category, action, label);
- _gat._getTrackerByName()._setCustomVar(index, name, value, scope);
- setTimeout('document.location = "' + link.href + '"', 100);
- }
- </script>
- ## Current OLS Login Button
- <a id="ols-login" href="http://online.k12.com/login/"><img alt="OLS Login" src="/sites/all/themes/custom/k12/img/k12-corporate/ols-login.png"></a>
- ## Modified OLS Login Button (sets custom segment on visitor)
- <a id="ols-login" href="http://online.k12.com/login/" onClick="recordCustomAndEvent(this, 'Interactions', 'Click', 'OLS', 1, 'User Type', 'Member', 1);return false;"><img alt="OLS Login" src="/sites/all/themes/custom/k12/img/k12-corporate/ols-login.png"></a>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement