PageSourceSearch

https://scarlxrd.co/wp-content/plugins/qt-chartvote/js/qt-chartvote-script.js?ver=1.2

js scarlxrd.co collected 2026-10-03 02:29:12 UTC 1,227 bytes, 45 lines download raw bytes

1/**
2 * @package QT Chartvote
3 * Script for the Qantumthemes Love It plugin
4 */
5
6
7(function($) {
8	"use strict";
9	$.fn.qtChartvoteInit = function(){
10		// var post_id, heart;
11		$("body a.qt-chartvote-link").off("click");
12		$("body a.qt-chartvote-link").on("click",function(e){
13			e.preventDefault();
14			e.stopPropagation();
15			var t = $(this);
16
17			var cookiename = 'voted-'+t.data('chartid')+'-'+t.data('position');
18			$.ajax({
19				type: "post",
20				url: chartvote_ajax_var.url,
21				cache: false,
22				data: "action=track-vote&nonce="+chartvote_ajax_var.nonce+"&position="+t.data('position')+"&move="+t.data('move')+"&chartid="+t.data('chartid'),
23				success: function(data){
24					console.log($.cookie(cookiename));
25					if( '1' !== $.cookie(cookiename)){
26						var dataarr = jQuery.parseJSON(data);
27						console.log('SUCCESS!');
28
29						console.log(dataarr);
30						t.parent().find(".qt-chartvote-number").html(dataarr.newvalue);
31						$.cookie(cookiename, '1', { path: '/' }); // session cookie only
32					} else {
33						alert("You already voted for this track");
34					}
35				},
36				error: function(e){
37					console.log(e.Error);
38				}
39			});
40		});
41	};
42	jQuery(document).ready(function() {
43		$.fn.qtChartvoteInit();
44	});
45})(jQuery);

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.