PageSourceSearch

https://www.youronlinechoices.com/uk/wp-content/themes/YourOptionsOnline/javascript/gears.js

js youronlinechoices.com collected 2026-09-24 06:54:42 UTC 6,597 bytes, 271 lines download raw bytes

1
2$(document).ready(function() {
3// --uk-- trebuie schimbat pentru fiecare tara in parte //
4
5
6
7    $('.mobileMenu').click(function() {
8        $('#menu-left-menu').slideToggle();
9    });
10
11    var survey_id = $('#survey_id').text();
12
13    $('.other_check').click(function() {
14        $(this).parent().find("input:text[name='other_text']").disabled = !this.checked;
15
16    });
17
18    //Action 1 - pentru start , 2 - pentru cancel , 5 - pentru finished, 3,4,6,7 - pentru update si insert
19
20    $("#start_survey").click(function() {
21
22        $.ajax({
23            type: "POST",
24            url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
25            data: {
26                action: '1',
27                survey_id: survey_id
28            },
29
30            success: function(response) {
31
32                console.log(response);
33
34            },
35            error: function() {
36
37
38            }
39        });
40    });
41
42    $("#end_survey").click(function() {
43
44        $.ajax({
45            type: "POST",
46            url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
47            data: {
48                action: '5',
49                survey_id: survey_id
50            },
51
52            success: function(response) {
53
54                console.log(response);
55
56            },
57            error: function() {
58
59
60            }
61        });
62
63    });
64
65    $("#end_survey2").click(function() {
66
67        $.ajax({
68            type: "POST",
69            url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
70            data: {
71                action: '5',
72                survey_id: survey_id
73            },
74
75            success: function(response) {
76
77                console.log(response);
78
79            },
80            error: function() {
81
82
83            }
84        });
85
86    });
87
88    
89
90    $(".next_button_only_check_has_other").click(function() {
91
92        var myForm = $(this).parent().parent().parent();
93        var question_id = myForm.find(':input:hidden').val();
94        var $inputs = myForm.find(':input:checked');
95        var other_text = $(this).parent().parent().parent().find("input:text[name='other_text']").val();
96
97
98        var values = {};
99        $inputs.each(function() {
100            values[this.name] = $(this).val();
101        });
102
103        if (typeof values['answer'] != 'undefined') {
104
105            var answer_id = values['answer'];
106
107            $.ajax({
108                type: "POST",
109                url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
110                data: {
111                    action: '4',
112                    answer_id: answer_id,
113                    other_text: other_text
114                },
115
116                success: function(response) {
117
118
119                    console.log(response);
120
121                },
122                error: function() {
123
124                    console.log("Error");
125                }
126            });
127        }
128
129    });
130
131    $(".next_button_only_check").click(function() {
132
133
134        var myForm = $(this).parent().parent().parent();
135        var question_id = myForm.find(':input:hidden').val();
136        var $inputs = myForm.find(':input:checked');
137
138
139
140        var values = {};
141        $inputs.each(function() {
142            values[this.name] = $(this).val();
143        });
144
145        
146
147        if (typeof values['answer'] != 'undefined') {
148
149            var answer_id = values['answer'];
150
151            $.ajax({
152                type: "POST",
153                url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
154                data: {
155                    action: '3',
156                    answer_id: answer_id
157                },
158
159                success: function(response) {
160
161                    console.log(response);
162
163                },
164                error: function() {
165
166
167                }
168            });
169        }
170    });
171
172    $(".next_button_multiple_check").click(function() {
173
174        var myForm = $(this).parent().parent().parent();
175        var question_id = myForm.find(':input:hidden').val();
176        var $inputs = myForm.find(':input:checked');
177
178
179
180        var values = {};
181        var aux = 0;
182        $inputs.each(function() {
183            values[$(this).val()] = parseInt(this.name.substr(this.name.length - 1));
184
185        });
186
187        $.ajax({
188            type: "POST",
189            url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
190            data: {
191                action: '6',
192                survey_id: survey_id,
193                data: values
194            },
195
196            success: function(response) {
197
198                console.log(response);
199
200            },
201            error: function() {
202
203
204            }
205        });
206
207
208
209    });
210
211
212 $(".next_button_only_input").click(function() {
213
214        var myForm = $(this).parent().parent().parent();
215        //var question_id = myForm.find(":input:hidden[name='hidden_id']").val();
216        //var answer_id = myForm.find(":input:hidden[name='hidden_answer_id']").val();
217        var question_id = myForm.find('input[type="hidden"][name="hidden_id"]').val();
218        var answer_id = myForm.find('input[type="hidden"][name="hidden_answer_id"]').val();
219        var other_text = $('textarea#only_input_textarea').val();
220
221        $.ajax({
222            type: "POST",
223            url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
224            data: {
225                action: '7',
226                survey_id: survey_id,
227                answer_id: answer_id,
228                question_id: question_id,
229                other_text: other_text
230            },
231
232            success: function(response) {
233
234                console.log(response);
235
236            },
237            error: function() {
238
239
240            }
241        });
242
243
244
245    });
246
247
248    $('body').on('click', '.mfp-close2', function() {
249
250        $.ajax({
251            type: "POST",
252            url: window.location.origin + "/uk/wp-content/themes/YourOptionsOnline/survey_handler.php",
253            data: {
254                action: '2',
255                survey_id: survey_id
256            },
257
258            success: function(response) {
259
260                console.log(response);
261
262            },
263            error: function() {
264
265
266            }
267        });
268
269    });
270
271});

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.