PageSourceSearch

https://cleopatraslots.info/wp-content/plugins/wp-tt-rating-stars/static/js/rating_ver-5.4.2.js

js cleopatraslots.info collected 2026-10-04 01:31:03 UTC 3,494 bytes, 68 lines download raw bytes

1var _____WB$wombat$assign$function_____=function(name){return (self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init(name))||self[name];};if(!self.__WB_pmw){self.__WB_pmw=function(obj){this.__WB_source=obj;return this;}}{
2let window = _____WB$wombat$assign$function_____("window");
3let self = _____WB$wombat$assign$function_____("self");
4let document = _____WB$wombat$assign$function_____("document");
5let location = _____WB$wombat$assign$function_____("location");
6let top = _____WB$wombat$assign$function_____("top");
7let parent = _____WB$wombat$assign$function_____("parent");
8let frames = _____WB$wombat$assign$function_____("frames");
9let opens = _____WB$wombat$assign$function_____("opens");
10(function($) {
11
12    $(document).on('click','.js-rating button',function() {
13        var ratingBox = $(this).closest('.js-rating');
14        var $el = $(this);
15        var id = ratingBox.data('id');
16        var total = ratingBox.data('total');
17        var rating = ratingBox.data('rating');
18        var num = parseInt($el.text(),10);
19        var is_cat = ratingBox.data('iscat');
20        var type = 'post';
21        if(is_cat == 1){
22            type = 'term';
23        }
24
25        if(ratingBox.hasClass('is-disabled')) {
26            return false;
27        }
28
29        $.ajax({
30            type: 'POST',
31            url: '?do=ajax',
32            data: {id:id,num:num,type:type},
33            success: function(pr) {          
34                if(pr === 'limit') {
35                    return false;
36                } else {
37                    ratingBox.addClass('is-disabled');
38                    $.cookie('vote-'+type+'-'+id, true, {expires: 7, path: '/' });
39                    ratingBox.find('.js-rating-view').css('width',pr+'%');
40                    var abs = ((rating*total+num)/++total); 
41                    abs = (abs^0)===abs?abs:abs.toFixed(1);           
42                    $('.js-rating-abs').text(abs);
43                    $('.js-rating-votes').text(total);
44                }
45            }
46        });
47
48        return false;
49    });
50
51})(jQuery);
52
53/*!
54 * jQuery Cookie Plugin v1.4.1
55 * https://github.com/carhartl/jquery-cookie
56 *
57 * Copyright 2006, 2014 Klaus Hartl
58 * Released under the MIT license
59 */
60!function(e){"function"==typeof define&&define.amd?define(["jquery"],e):e("object"==typeof exports?require("jquery"):jQuery)}(function(e){function n(e){return u.raw?e:encodeURIComponent(e)}function o(e){return u.raw?e:decodeURIComponent(e)}function i(e){return n(u.json?JSON.stringify(e):e+"")}function r(e){0===e.indexOf('"')&&(e=e.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"))
61try{return e=decodeURIComponent(e.replace(c," ")),u.json?JSON.parse(e):e}catch(n){}}function t(n,o){var i=u.raw?n:r(n)
62return e.isFunction(o)?o(i):i}var c=/\+/g,u=e.cookie=function(r,c,a){if(arguments.length>1&&!e.isFunction(c)){if(a=e.extend({},u.defaults,a),"number"==typeof a.expires){var f=a.expires,s=a.expires=new Date
63s.setTime(+s+864e5*f)}return document.cookie=n(r)+"="+i(c)+(a.expires?"; expires="+a.expires.toUTCString():"")+(a.path?"; path="+a.path:"")+(a.domain?"; domain="+a.domain:"")+(a.secure?"; secure":"")}for(var d=r?void 0:{},p=document.cookie?document.cookie.split("; "):[],m=0,x=p.length;x>m;m++){var l=p[m].split("="),k=o(l.shift()),v=l.join("=")
64if(r&&r===k){d=t(v,c)
65break}r||void 0===(v=t(v))||(d[k]=v)}return d}
66u.defaults={},e.removeCookie=function(n,o){return void 0===e.cookie(n)?!1:(e.cookie(n,"",e.extend({},o,{expires:-1})),!e.cookie(n))}})
67
68}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.