NOTICE: By continued use of this site you understand and agree to the binding Terms of Service and Privacy Policy.
// ==UserScript== // @name Session bug test // @namespace http://tampermonkey.net/ // @version 0.3 // @description try to take over the world! // @author You // @match http://devmo.torcello.fr/studio/* // @grant none // @license MIT // ==/UserScript== (function() { function getBrowser() { if((navigator.userAgent.indexOf("Opera") || navigator.userAgent.indexOf('OPR')) != -1 ){ return ('Opera'); } else if(navigator.userAgent.indexOf("Chrome") != -1 ){ return ('Chrome'); } else if(navigator.userAgent.indexOf("Safari") != -1){ return ('Safari'); } else if(navigator.userAgent.indexOf("Firefox") != -1 ){ return ('Firefox'); } else if((navigator.userAgent.indexOf("MSIE") != -1 ) || (!!document.documentMode == true )){ return ('IE'); } else{ return ('unknown'); } } setTimeout(function() { var browser = getBrowser() var value = $('.studio-menu-right .add-to-cart').length ? 'connected' : 'DISCONNECTED'; $.ajax ({ type: "GET", url: "http://devmo.torcello.fr/test.php?browser=" + browser + "&value="+value+"&action=w", dataType: 'json', success: function (data){ console.log(data) } }); $('.studio-menu-right .add-to-cart').length }, 10000); setTimeout(function () { if ($('.studio-menu-right .add-to-cart').length) { location.reload(); } }, 180000) })();