Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var itemId = 1344533;
- var format = "zip";
- var time = "1466708642";
- $(document).ready(function () {
- var isVis = true;
- if (typeof(vis) !== 'undefinend') {
- vis(function () {
- isVis = vis();
- });
- }
- var totalTime = 0;
- var waitTime = 10000;
- var timer = null;
- function countDown() {
- if (isAb()) {
- $('#adblocked').show();
- $('#pleasewait-adblock').show();
- waitTime = 60000;
- }
- if (timer)
- clearInterval(timer);
- if (!isAb() || isVis)
- totalTime += 1000;
- $('.countdown').html((waitTime - totalTime) / 1000);
- if (totalTime < waitTime)
- timer = setInterval(countDown, 1000);
- else {
- document.location.href = '/downloads/thankyou/id/' + itemId + '/format/' + format + "/sess/" + time;
- }
- }
- $('#downloadbutton').on('click', function () {
- setTimeout(function () {
- document.location.href = '/downloads/thankyou/id/' + itemId + '/format/' + format + "/sess/" + time;
- }, 1000);
- });
- countDown();
- });
- function isAb() {
- if (isVIP())
- return false;
- if (typeof window.iHaveLoadedAds === 'undefined') {
- return true;
- }
- if (typeof window.gadsize === 'undefined') {
- return true;
- }
- return !(window.iHaveLoadedAds);
- }
- (function (c) {
- if (c)
- document.addEventListener(eventKey, c);
- return !document[stateKey];
- })
Advertisement
Add Comment
Please, Sign In to add comment