This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| riveted.init({ | |
| eventHandler: function(data) { | |
| if (data == 10) { | |
| ga('send', 'event', 'Non-Bounce', 'True'); | |
| } | |
| } | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cat input.csv | sed "1 d" > output.csv |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var detectIOSMultitask = function(callback) { | |
| var inMultitask; | |
| function report(event) { | |
| callback({ event: event, width: document.documentElement.clientWidth, height: document.documentElement.clientHeight }); | |
| } | |
| if (navigator.userAgent.match(/iPad/i) == null) { | |
| return; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script> | |
| detectIOSMultitask(function(data) { | |
| // data.event = 'load', 'enter', or 'exit' | |
| console.log( data['event'], data['width'], data['height'] ); | |
| // Example Google Analytics event | |
| ga('send', 'event', 'iOS Multitask', data['event'], data['width'] + 'x' + data['height'], {'nonInteraction': 1}); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var active = false; | |
| function changeRefer(details) { | |
| if (!active) return; | |
| for (var i = 0; i < details.requestHeaders.length; ++i) { | |
| if (details.requestHeaders[i].name === 'Referer') { | |
| details.requestHeaders[i].value = 'http://www.google.com/'; | |
| break; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 2-1: 13/11, 6/5 | |
| 3-1: 8/5, 6/5 | |
| 4-1: 24/23, 13/9 | |
| 5-1: 24/23, 13/8 | |
| 6-1: 13/7, 8/7 | |
| 3-2: 24/21, 13/11 | |
| 4-2: 8/4, 6/4 | |
| 5-2: 24/22, 13/8 | |
| 6-2: 24/18, 13/11 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if (document.documentElement.clientWidth < 600) { | |
| jQuery.scrollDepth(); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var videoPlaying; | |
| var v = document.getElementsByTagName("video")[0]; | |
| // When the video starts | |
| v.addEventListener('playing', function() { | |
| // Poll the video every 5 seconds and keep the Riveted timer going | |
| videoPlaying = setInterval(function() { | |
| if (!v.paused) { | |
| riveted.trigger(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script src="riveted.min.js"></script> | |
| <script>riveted.init();</script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| javascript:(function(){var%20el=document.createElement('div'),b=document.getElementsByTagName('body')[0];function%20getScript(url,success){var%20script=document.createElement('script');script.src=url;var%20head=document.getElementsByTagName('head')[0],done=false;script.onload=script.onreadystatechange=function(){if(!done%20%26%26(!this.readyState||%20this.readyState=='loaded'||%20this.readyState=='complete')){done=true;success();script.onload=script.onreadystatechange=null;head.removeChild(script);}};head.appendChild(script);}getScript('//code.jquery.com/jquery.min.js',function(){$jq=jQuery.noConflict();$jq('._GAgL').on('click',function(e){var%20$e=$jq(e.target);var%20a=$e.text();var%20b=$e.parents('._GAZt').next('._GAZt').find('._GAgL').text();var%20res=Math.round(parseInt(a,10)/%20parseInt(b,10)*100)+'%25';$e.append('%3Csmall%20style=%22color:%23666%22%3E%20'+res+'%3C/small%3E')});});})(); |