PageSourceSearch

https://yzex.co/premium_script.js?lang=en&ver=1791329903

js yzex.co collected 2026-10-06 20:38:45 UTC 30,162 bytes, 1,200 lines download raw bytes

1jQuery(function($) {
2
3 	$('.ajax_post_form').ajaxForm({
4		dataType: 'json',
5		beforeSubmit: function(a, f, o) {
6			f.addClass('thisactive');
7			$('.thisactive input[type=submit], .thisactive input[type=button]').attr('disabled',true);
8			$('.thisactive').find('.ajax_submit_ind').show();
9		},
10		error: function(res, res2, res3) {
11			        for (key in res) {
12        console.log(key + ' = ' + res[key]);
13        }
14        		},
15		success: function(res) {
16					
17			if (res['status'] == 'error') {
18				if (res['status_text']) {
19					$('.thisactive .resultgo').html('<div class="resultfalse"><div class="resultclose"></div>' + res['status_text'] + '</div>');
20				}
21			}	
22			
23			if (res['status'] == 'success') {
24				if (res['status_text']) {
25					$('.thisactive .resultgo').html('<div class="resulttrue"><div class="resultclose"></div>' + res['status_text'] + '</div>');
26				}
27			}
28			
29			if (res['clear']) {
30				$('.thisactive input[type=text]:not(.notclear), .thisactive input[type=password]:not(.notclear), .thisactive textarea:not(.notclear)').val('');
31			}
32
33			if (res['show_hidden']) {
34				$('.thisactive .hidden_line').show();
35			}			
36					
37			if (res['url']) {
38				window.location.href = res['url']; 
39			}
40						
41					if (res['ncapt1']) {
42			$('.captcha1').attr('src', res['ncapt1']);
43		}
44		
45		if (res['ncapt2']) {
46			$('.captcha2').attr('src', res['ncapt2']);
47		}
48		
49		if (res['nsymb']) {
50			$('.captcha_sym').html(res['nsymb']);
51		}	
52		
53		$('.captcha_value').val('');
54					
55			$('.thisactive input[type=submit], .thisactive input[type=button]').attr('disabled', false);
56			$('.thisactive').find('.ajax_submit_ind').hide();
57			$('.thisactive').removeClass('thisactive');	
58			
59		}
60	});
61	
62	if (self != top && window.parent.frames.length > 0) {
63		$('.not_frame').remove();
64	}  
65	
66	});		
67	
68jQuery(function($) { 
69
70 	function get_exchange_step1(id) {
71		
72		var id1 = $('#select_give').val();
73		var id2 = $('#select_get').val();
74		$('.exch_ajax_wrap_abs').show();	
75		var param = 'id=' + id + '&id1=' + id1 + '&id2=' + id2;
76		$.ajax({
77			type: "POST",
78			url: "https://yzex.co/premium_site_action-exchange_stepselect.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en",
79			dataType: 'json',
80			data: param,
81			error: function(res, res2, res3) {
82				        for (key in res) {
83        console.log(key + ' = ' + res[key]);
84        }
85        			},			
86			success: function(res)
87			{	
88				$('.exch_ajax_wrap_abs').hide();
89				
90				if (res['status'] == 'success') {
91					
92					$('#exch_html').html(res['html']);	
93
94					if ($('#the_title_page').length > 0) {
95						$('#the_title_page, .direction_title').html(res['titlepage']);
96					}	
97					
98					$('title').html(res['title']);
99					
100					if ($('meta[name=keywords]').length > 0) {
101						$('meta[name=keywords]').attr('content', res['keywords']);
102					}
103					if ($('meta[name=description]').length > 0) {
104						$('meta[name=description]').attr('content', res['description']);
105					}
106					
107					if (res['url']) {
108						window.history.replaceState(null, null, res['url']);
109					}				
110					
111						$(document).JTimer();
112		$(document).Jselect('init', {trigger: '.js_my_sel', class_ico: 'currency_logo'});
113		$(document).JcheckboxInit();
114					} else {
115					        if (res['status_text']) {
116        alert(res['status_text']);
117        }
118        				}	
119			}
120		});		
121		
122	}
123	$(document).on('change', '#select_give', function() {
124		
125		get_exchange_step1(1);
126		
127	});
128	$(document).on('change', '#select_get', function() {
129		
130		get_exchange_step1(2);
131		
132	});	
133	
134});	
135jQuery(function($) { 
136	
137	var res_timer = 1;
138	function start_res_timer() {
139		$('.res_timer').html('0');
140		
141		if (res_timer == 1) {
142			res_timer = 0;
143			setInterval(function() { 
144				if ($('.res_timer').length > 0) {
145					var num_t = parseInt($('.res_timer').html());
146					num_t = num_t + 1;
147					$('.res_timer').html(num_t);
148				}
149			},1000);
150		}
151	}	
152	
153	$('#check_rule_step').on('change',function() {
154		
155		if ($(this).prop('checked')) {
156			$('#check_rule_step_input').prop('disabled', false);
157		} else {
158			$('#check_rule_step_input').prop('disabled', true);
159		}
160		
161	});
162
163	$('#check_rule_step_input').on('click',function() {
164		
165		$(this).parents('.ajax_post_form').find('.resultgo').html('<div class="resulttrue">Processing. Please wait (<span class="res_timer">0</span>)</div>');
166		start_res_timer();
167		
168	});	
169			
170});		
171jQuery(function($) { 
172	
173	$('.iam_pay_bids').on('click', function() {
174		if (!confirm("Are you sure that you paid your order?")) {
175			return false;
176		}
177	});		
178			
179});		
180jQuery(function($) {
181	
182	if ($('.check_payment_hash').length > 0) {
183		var nowdata = 0;
184		var redir = 0;
185			
186		function check_payment_now() {
187			var second = parseInt($('.check_payment_hash').attr('data-time'));
188		
189			nowdata = parseInt(nowdata) + 1;
190
191				$('.block_check_payment_abs').html(nowdata);
192	$('.block_check_payment').show();
193	var wid = $('.block_check_payment').width();
194	if (wid > 1) {
195		var onepr = wid / second;
196		var nwid = onepr * nowdata;
197		if (nwid > wid) { nwid = wid; }
198		$('.block_check_payment_ins').animate({'width': nwid}, 500);
199	}
200				
201			if (nowdata >= second) {
202				if (redir == 0) {
203					var durl = $('.check_payment_hash').attr('data-hash');
204					redir = 1;
205					if (durl.length > 0) {
206						$('.exchange_status_abs').show();
207						
208						var param = 'hashed=' + durl;
209						$.ajax({
210							type: "POST",
211							url: "https://yzex.co/premium_site_action-refresh_status_bids.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en&auto_check=1",
212							dataType: 'json',
213							data: param,
214							error: function(res, res2, res3) {
215								        for (key in res) {
216        console.log(key + ' = ' + res[key]);
217        }
218        							},			
219							success: function(res)
220							{
221								$('.exchange_status_abs').hide();
222								if (res['html']) {
223									$('#exchange_status_html').html(res['html']);
224										$(document).JTimer();
225		$(document).Jselect('init', {trigger: '.js_my_sel', class_ico: 'currency_logo'});
226		$(document).JcheckboxInit();
227										redir = 0;
228									nowdata = 0;
229								} 
230							}
231						});	
232					}					
233				}
234			}
235		}
236		setInterval(check_payment_now,1000);
237	}
238	
239});		
240	
241	jQuery(function($) { 
242	
243		$(document).on('click', '.js_window_login', function() {
244			$(document).JsWindow('show', {
245				window_class: 'update_window',
246				title: 'Authorization',
247				content: $('.loginform_box_html').html(),
248				insert_div: '.loginform_box',
249				shadow: 1
250			});		
251			
252			var new_url = window.location.href;
253			$('input[name=return_url]').val(new_url);
254			
255			return false;
256		});	
257		
258	});	
259		
260	jQuery(function($) { 
261	
262		$(document).on('click', '.js_window_join', function() {
263			
264			$(document).JsWindow('show', {
265				window_class: 'update_window',
266				title: 'Sign up',
267				content: $('.registerform_box_html').html(),
268				insert_div: '.registerform_box',
269				shadow: 1
270			});		
271			
272			var new_url = window.location.href;
273			$('input[name=return_url]').val(new_url);
274			
275			return false;
276		});
277		
278	});	
279		jQuery(function($) {
280		
281		var clipboard = new ClipboardJS('.js_copy');
282		clipboard.on('success', function(e) {
283			$('.js_copy').removeClass('copied');
284			$(e.trigger).addClass('copied');	
285		});	
286		
287	});
288		
289	jQuery(function($) { 
290	
291		$(document).on('click', '.oncetoggletitle', function() {
292			
293			$(this).parents('.oncetoggle').toggleClass('active');
294			
295			return false;
296		});
297		
298	});		
299		jQuery(function($) {
300		
301		$(document).on('focusin', '.has_tooltip input, .has_tooltip textarea', function() {
302			$(this).parents('.has_tooltip').addClass('showed');
303		});
304		
305		$(document).on('click', '.field_tooltip_label', function() {
306			$(this).parents('.has_tooltip').addClass('showed');
307		});
308		
309		$(document).on('focusout', '.has_tooltip input, .has_tooltip textarea', function() {
310			$(this).parents('.has_tooltip').removeClass('showed');
311		});	
312		
313		$(document).on('click', '.form_field_line input, .form_field_line textarea', function() {
314			$(this).removeClass('error');
315		});
316		
317	});
318	jQuery(function($) { 
319
320	$(document).on('click', '.captcha_reload', function() {
321		var thet = $(this);
322		thet.addClass('act');
323		var param ='have=reload';
324		$.ajax({
325			type: "POST",
326			url: "https://yzex.co/premium_site_action-captcha_reload.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en",
327			dataType: 'json',
328			data: param,
329			error: function(res, res2, res3) {
330				        for (key in res) {
331        console.log(key + ' = ' + res[key]);
332        }
333        			},		
334			success: function(res)
335			{
336				if (res['ncapt1']) {
337					$('.captcha1').attr('src', res['ncapt1']);
338				}
339				
340				if (res['ncapt2']) {
341					$('.captcha2').attr('src', res['ncapt2']);
342				}
343				
344				if (res['nsymb']) {
345					$('.captcha_sym').html(res['nsymb']);
346				}
347				
348				$('.captcha_value').val('');
349				thet.removeClass('act');
350			}
351		});
352			
353		return false;
354	});
355	
356});	
357	
358jQuery(function($) {	
359		
360	$(document).on('focusin', '.js_window_wrap',function() {
361		$(this).addClass('showed');
362	});	
363	
364	$(document).on('focusout', '.js_window_wrap',function() {
365		$(this).removeClass('showed');
366	});	
367		
368});
369	 
370	jQuery(function($) { 
371	
372		$(document).on('click', '.js_hnotice_close', function() {
373			var id = $(this).parents('.js_hnotice').attr('id').replace('hnotice_', '');
374			var exp_day = parseInt($(this).attr('data-exp'));
375			
376			$(document).PHPCookie('set', {key: "hm" + id, value: 1, domain: 'https://yzex.co/', days: exp_day});
377			
378			$('#hnotice_' + id).hide();
379		});
380		
381		$(document).on('click', '.wn_div_submit', function() {
382			var id = $(this).attr('data-id');
383			var exp_day = parseInt($(this).attr('data-exp'));
384			
385			$(document).PHPCookie('set', {key: "hm" + id, value: 1, domain: 'https://yzex.co/', days: exp_day});
386			
387			$(this).parents('.wn_wrap').hide();
388		});	
389		
390	});	
391		
392jQuery(function($) { 
393
394    $(".promo_menu li a").on('click',function () {
395        if (!$(this).hasClass('act')) {
396		    $(".pbcontainer, .promo_menu li").removeClass('act');
397		    $(".pbcontainer").filter(this.hash).addClass('act');
398		    $(this).parents('li').addClass('act');
399        }
400		
401        return false;
402    });
403	
404    $(".bannerboxlink a").on('click',function() {
405        var text = $(this).text();
406		var st = $(this).attr('show-title');
407		var ht = $(this).attr('hide-title');
408        if (text == st) {
409            $(this).html(ht);
410        } else {
411            $(this).html(st);
412        }
413        $(this).parents(".bannerboxone").find(".bannerboxtextarea").toggle();
414	    $(this).toggleClass('act');
415
416        return false;
417    });
418	
419});	
420	
421jQuery(function($) { 
422
423	$(document).on('click', '.js_add_userwallet', function() {
424		
425		$(document).JsWindow('show', {
426			window_class: 'update_window',
427			title: 'Add account',
428			content: $('.userwalletsform_box_html').html(),
429			insert_div: '.userwalletsform_box',
430			shadow: 1
431		});		
432		
433        var id = $(this).attr('data-currid');		
434		$('.userwalletsform_currency_id').val(id);
435		
436        var account = $(this).attr('data-account');		
437		$('.userwalletsform_account').val(account);				
438		
439        var redir = $(this).attr('data-redir');		
440		$('#userwalletsform_redir').val(redir);		
441		
442	    return false;
443	});	
444	
445});	
446	
447jQuery(function($) { 
448
449    $(document).on('click', '.js_userwallet_verify', function() {
450
451		var id = $(this).attr('data-id');
452		var redir = $(this).attr('data-redir');
453		var thet = $(this);
454		if (!thet.hasClass('act')) {
455			thet.addClass('act');
456			var param = 'id=' + id + '&redir=' + redir;
457			$.ajax({
458				type: "POST",
459				url: "https://yzex.co/premium_site_action-info_userwallets.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en",
460				dataType: 'json',
461				data: param,
462				error: function(res, res2, res3) {
463					        for (key in res) {
464        console.log(key + ' = ' + res[key]);
465        }
466        				},			
467				success: function(res)
468				{
469					if (res['status'] == 'success') {
470						$(document).JsWindow('show', {
471							window_class: 'walletverify_window',
472							title: 'Verify wallet',
473							content: res['html'],
474							insert_div: '.walletsverify_box',
475							shadow: 1
476						});						
477					} 
478					if (res['status'] == 'error') {
479						        if (res['status_text']) {
480        alert(res['status_text']);
481        }
482        					}
483					thet.removeClass('act');
484				}
485			});			
486		}
487
488        return false;
489    });
490	
491    $(document).on('click','.verify_action_button', function() {
492		
493		var thet = $(this);
494		var id = thet.attr('data-id');
495		var wait_title = thet.attr('data-title');
496		var redir = thet.attr('data-redir');
497		$('.resultgo_walletverify').html('<div class="resulttrue">' + wait_title + '</div>');
498		
499		if (!thet.prop('disabled')) {
500			thet.prop('disabled', true);
501		
502			var param ='id=' + id + '&redir=' + redir;
503			$.ajax({
504				type: "POST",
505				url: "https://yzex.co/premium_site_action-accountverify.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en",
506				dataType: 'json',
507				data: param,
508				error: function(res, res2, res3) {
509					        for (key in res) {
510        console.log(key + ' = ' + res[key]);
511        }
512        				},			
513				success: function(res)
514				{
515					
516					if (res['status'] == 'error') {
517						$('.resultgo_walletverify').html('<div class="resultfalse">' + res['status_text'] + '</div>');
518					}
519					
520					if (res['status'] == 'success') {
521						$(document).JsWindow('hide');
522					}
523					
524					if (res['url']) {
525						window.location.href = res['url']; 
526					}
527					
528					thet.prop('disabled', false);
529				}
530			});
531		}
532	
533        return false;
534    });	
535
536});	
537jQuery(function($) { 
538
539    $(document).on('click', function(event) {
540        if ($(event.target).closest(".js_choice_link").length) return;
541        $('.js_choice_ul').hide();		
542		
543        event.stopPropagation();
544    });	
545	
546	$(document).on('click', '.js_choice_link', function() {
547		
548		$(this).parents('.js_window_wrap').find('.js_choice_ul').show();
549		
550		return false;
551	});
552	
553	$(document).on('click', '.js_choice_line', function() {
554		
555		var account = $(this).attr('data-choice');
556		$(this).parents('.js_window_wrap').find('input').val(account).trigger("change");
557		$('.js_choice_ul').hide();
558		
559		return false;
560	});
561
562});	
563	
564jQuery(function($) {	
565
566function create_icons() {
567	
568	$('.js_icon_left').hide();
569	$('.js_icon_left:first').show();
570	
571	$('.js_icon_left').each(function() {
572		
573		var vtype = $(this).attr('data-type');
574		if ($('.js_item_left_' + vtype).length > 0) {
575			$('.js_icon_left_' + vtype).show();
576		}
577		
578	});	
579	
580	$('.js_icon_right').hide();
581	$('.js_icon_right:first').show();	
582		
583	$('.js_icon_right').each(function() {
584		
585		var vtype = $(this).attr('data-type');
586		if ($('.js_item_right_' + vtype + ':visible').length > 0) {
587			$('.js_icon_right_' + vtype).show();
588		}
589		
590	});		
591		
592	if ($('.js_icon_right.active:visible').length == 0) {
593		
594		$('.js_item_right').show();
595		$('.js_icon_right').removeClass('active');
596		$('.js_icon_right:first').addClass('active');
597		
598	}
599	
600}
601
602create_icons();
603
604function go_active_left_col() {
605	
606	if ($('.xtt_html_abs').length > 0) {
607		if ($('.js_item_left:visible.active').length == 0) {
608			$('.js_item_left').removeClass('active');
609			$('.js_item_left:visible:first').addClass('active');
610		}		
611		var valid = $('.js_item_left.active').attr('data-id');
612
613		$('.xtt_html_abs').show();
614		var param ='id=' + valid;
615		$.ajax({
616			type: "POST",
617			url: "https://yzex.co/premium_site_action-table1_change.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en",
618			dataType: 'json',
619			data: param,
620			error: function(res, res2, res3) {
621				        for (key in res) {
622        console.log(key + ' = ' + res[key]);
623        }
624        			},       
625			success: function(res)
626			{
627				$('.xtt_html_abs').hide();
628				if (res['status'] == 'success') {
629					$('#xtt_right_col_html').html(res['html']);
630				} 	
631				create_icons();
632			}
633		});	
634	}	
635	
636}
637	
638    $(document).on('click',".js_item_left", function() {
639		
640        if (!$(this).hasClass('active')) {
641			$(".js_item_left").removeClass('active');
642			$(this).addClass('active');
643			go_active_left_col();
644        }
645		
646        return false;
647    });
648	
649    $(document).on('click',".js_icon_left", function () {
650		
651        if (!$(this).hasClass('active')) {
652			var vtype = $(this).attr('data-type');
653			$(".js_icon_left").removeClass('active');
654			$(this).addClass('active');
655			if (vtype == 0) {
656				$('.js_item_left').show();
657			} else {
658				$('.js_item_left').hide();
659				$('.js_item_left_' + vtype).show();
660			}
661			go_active_left_col();
662        }
663		
664        return false;
665    });
666	
667    $(document).on('click',".js_icon_right", function () {
668		
669        if (!$(this).hasClass('active')) {
670			var vtype = $(this).attr('data-type');
671			$(".js_icon_right").removeClass('active');
672			$(this).addClass('active');
673			if (vtype == 0) {
674				$('.js_item_right').show();
675			} else {
676				$('.js_item_right').hide();
677				$('.js_item_right_' + vtype).show();
678			}
679        }
680		
681        return false;
682    });	
683	
684    $(document).on('click',".xtt_title_link", function() {
685		
686		$('.xtt_title_link').removeClass('active');
687		$(this).addClass('active');
688		var id = $(this).attr('data-id');
689		
690		$(document).PHPCookie('set', {key: "table5_select", value: id, domain: 'https://yzex.co/', days: '30'});
691		
692		$('.js_check_reserve').each(function() {
693			
694			var data_now = $(this).attr('data-reserve');
695			if (id == 'rate') {
696				data_now = $(this).attr('data-rate');
697			}
698			$(this).html(data_now);
699			
700		});
701		
702        return false;
703    });	
704	
705});			
706	
707jQuery(function($) { 
708
709	if ($('#hexch_html').length > 0) {
710		$(document).on('click', '.js_exchange_link', function() {
711
712			$('.js_exchange_link').removeClass('active');
713			$(this).addClass('active');
714				
715			var direction_id = $(this).attr('data-direction-id'); 
716				
717			$('.js_exchange_widget_abs').show();
718				
719			var tscroll = $('#hexch_html').offset().top - 100;
720			$('body,html').animate({scrollTop : tscroll}, 500);
721				
722			var param = 'direction_id=' + direction_id;
723			$.ajax({
724				type: "POST",
725				url: "https://yzex.co/premium_site_action-exchange_widget.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en",
726				dataType: 'json',
727				data: param,
728				error: function(res, res2, res3){
729					        for (key in res) {
730        console.log(key + ' = ' + res[key]);
731        }
732        				},					
733				success: function(res)
734				{
735					if (res['html']) {
736						$('#hexch_html').html(res['html']);
737					}
738					if (res['status'] == 'error') {
739						$('#hexch_html').html('<div class="resultfalse"><div class="resultclose"></div>' + res['status_text'] + '</div>');
740					}
741						$(document).JTimer();
742		$(document).Jselect('init', {trigger: '.js_my_sel', class_ico: 'currency_logo'});
743		$(document).JcheckboxInit();
744						$('.js_exchange_widget_abs').hide();
745						
746												
747				}
748			});	
749			
750			return false;
751		});
752	}
753	
754});
755	
756jQuery(function($) {
757	
758	$(document).on('click', '.js_amount', function() {
759		
760		var amount = $(this).attr('data-val');
761		var id = $(this).attr('data-id');
762		$('input.js_' + id + ':not(:disabled)').val('0').trigger('keyup');
763		$('input.js_' + id + ':not(:disabled)').val(amount).trigger('change');
764		$('.js_' + id + '_html').html(amount);
765		
766	});		
767	
768	function cache_exchange_data(thet) {
769		
770		var ind = 0;
771		if (thet.hasClass('check_cache')) {
772						
773				ind = 1;
774				
775				var not_check_data = 0;
776				if ($('#not_check_data').length > 0) {
777					if ($('#not_check_data').prop('checked')) {
778						not_check_data = 1;
779					}
780				} else {
781					not_check_data = '0';	
782				}
783				if (not_check_data == 1) {
784					ind = 0;
785				}				
786			
787					} else {
788			ind = 1;
789		}
790		if (ind == 1) {
791			var id = thet.attr('cash-id');
792			var v = thet.val();
793			$(document).PHPCookie('set', {key: "cache_" + id, value: v, domain: 'https://yzex.co/', days: '30'});	
794		}
795		
796	}
797	
798	$(document).ChangeInput({ 
799		trigger: '.cache_data',
800		success: function(obj) {
801			
802			cache_exchange_data(obj);
803			
804		}
805	});	
806	
807	$(document).on('change', '#not_check_data', function() {
808		
809		if ($(this).prop('checked')) {
810			$(document).PHPCookie('set', {key: "not_check_data", value: 1, domain: 'https://yzex.co/', days: '30'});
811			$('.check_cache').each(function() {
812				var id = $(this).attr('cash-id');
813				$(document).PHPCookie('set', {key: "cache_" + id, value: '', domain: 'https://yzex.co/', days: '30'});
814			});	
815		} else {
816			$(document).PHPCookie('set', {key: "not_check_data", value: 0, domain: 'https://yzex.co/', days: '30'});
817			$('.check_cache').each(function() {
818				var id = $(this).attr('cash-id');
819				var v = $(this).val();
820				$(document).PHPCookie('set', {key: "cache_" + id, value: v, domain: 'https://yzex.co/', days: '30'});
821			});		
822		}
823		
824	});
825	
826	$(document).on('change', 'select, textarea, input:not(.js_sum_val)', function() {
827		
828		$(this).parents('.js_wrap_error').removeClass('error');
829		
830	});
831	
832	$(document).on('click', 'input, textarea, select', function() {
833		
834		$(this).parents('.js_wrap_error').removeClass('error');
835		
836	});	
837	
838	$(document).on('click', '.ajax_post_bids input[type=submit]', function() {
839		
840		var count_window = $('.window_message').length;
841		if (count_window > 0) {
842			
843			$(document).JsWindow('show', {
844				window_class: 'update_window',
845				close_class: 'js_direction_window_close_no',
846				title: 'Attention!',
847				content: $('.window_message').html(),
848				shadow: 1,
849				enable_button: 1,
850				button_title: 'OK',
851				button_class: 'js_window_close js_direction_window_close'
852			});			
853			
854			return false;
855		} 
856		
857	});
858	
859    $(document).on('click', '.js_direction_window_close', function() {
860		
861		$('.ajax_post_bids').submit();
862		
863    });	
864	
865	var res_timer = '';
866	function start_res_timer() {
867		
868		$('.res_timer').html('0');
869		clearInterval(res_timer);
870		
871		res_timer = setInterval(function() { 
872			if ($('.res_timer').length > 0) {
873				var num_t = parseInt($('.res_timer').html());
874				num_t = num_t + 1;
875				$('.res_timer').html(num_t);				
876			}
877		}, 1000);
878	}
879	
880    $('.ajax_post_bids').ajaxForm({
881        dataType:  'json',
882		beforeSubmit: function(a, f, o) {
883			
884			f.addClass('thisactive');
885			$('.thisactive input[type=submit], .thisactive input[type=button]').attr('disabled', true);
886			$('.ajax_post_bids_res').html('<div class="resulttrue">Processing. Please wait (<span class="res_timer">0</span>)</div>');
887			
888			start_res_timer();
889			
890			$('.ajax_post_bids_res').find('.js_wrap_error').removeClass('error');
891			
892			        },
893		error: function(res, res2, res3) {
894			
895			$('.ajax_post_bids_res').html('<div class="resultfalse">Script error</div>');
896			        for (key in res) {
897        console.log(key + ' = ' + res[key]);
898        }
899        			
900		},		
901        success: function(res) { 
902		
903			if (res['error_fields']) {
904				$.each(res['error_fields'], function(index, value) {
905					add_error_field(index, value);
906				});					
907			}		
908			
909			if (res['status'] && res['status'] == 'error') {
910				$('.ajax_post_bids_res').html('<div class="resultfalse"><div class="resultclose"></div>' + res['status_text'] + '</div>');
911				if ($('.js_wrap_error.error').length > 0) {
912					var ftop = $('.js_wrap_error.error:first').offset().top - 100;
913					$('body, html').animate({scrollTop: ftop}, 500);
914				}
915			}
916			
917			if (res['status'] && res['status'] == 'success') {
918				$('.ajax_post_bids_res').html('<div class="resulttrue"><div class="resultclose"></div>' + res['status_text'] + ' (<span class="res_timer">0</span>)</div>');
919				start_res_timer();
920			}				
921		
922			if (res['url']) {
923				window.location.href = res['url']; 
924			}
925			
926					if (res['ncapt1']) {
927			$('.captcha1').attr('src', res['ncapt1']);
928		}
929		
930		if (res['ncapt2']) {
931			$('.captcha2').attr('src', res['ncapt2']);
932		}
933		
934		if (res['nsymb']) {
935			$('.captcha_sym').html(res['nsymb']);
936		}	
937		
938		$('.captcha_value').val('');
939		
940		    $('.thisactive input[type=submit], .thisactive input[type=button]').attr('disabled', false);
941			$('.thisactive').removeClass('thisactive');
942			
943        }
944    });	
945	
946	function add_error_field(id, text) {
947		
948		$('.js_' + id).parents('.js_wrap_error').addClass('error');
949		$('.js_' + id).parents('.js_line_wrapper').show();
950		if (text.length > 0) {
951			$('.js_' + id + '_error').html(text).show();
952		}
953		
954	}	
955	function remove_error_field(id) {
956		
957		$('.js_' + id).parents('.js_wrap_error').removeClass('error');
958		
959	}	
960
961	function calc_set_value(the_obj, the_num) {
962		
963		$(the_obj).val(the_num);	}
964	
965	function calc_set_html(the_obj, the_num) {
966		
967		$(the_obj).html(the_num);	}	
968	
969	function collect_other_data() {
970		
971		var set_data = 'sd=1';
972		$('.js_changecalc').each(function() {
973			var nv = $(this).attr('name');
974			if (nv.length > 0) {
975				var tv = $(this).attr('type');
976				var vv = $(this).val();
977				if (tv == 'checkbox') {
978					if (!$(this).prop('checked')) {
979						vv = 0;
980					}
981				} 
982				set_data = set_data + '&' + nv + '=' + vv;
983			}
984		});	
985		
986		return encodeURIComponent(set_data);
987	}
988	
989	function go_calc(obj, dej) {
990		
991		var cd = collect_other_data();
992		var sum = obj.val().replace(/,/g,'.');
993		var id = $('.js_direction_id:first').val();
994		var param = 'id=' + id + '&sum=' + sum + '&dej=' + dej + '&cd=' + cd;
995		
996				
997		$('.exch_ajax_wrap_abs, .js_exchange_widget_abs, .js_loader').show();
998		
999		if (dej == 1) {
1000			calc_set_value('input.js_sum1:not(:focus)', sum);
1001			calc_set_html('.js_sum1_html', sum);
1002		} else if (dej == 2) {
1003			calc_set_value('input.js_sum2:not(:focus)', sum);
1004			calc_set_html('.js_sum2_html', sum);					
1005		} else if (dej == 3) {
1006			calc_set_value('input.js_sum1c:not(:focus)', sum);
1007			calc_set_html('.js_sum1c_html', sum);
1008		} else if (dej == 4) {
1009			calc_set_value('input.js_sum2c:not(:focus)', sum);
1010			calc_set_html('.js_sum2c_html', sum);				
1011		}
1012
1013		remove_error_field('sum1');
1014		remove_error_field('sum2');
1015		remove_error_field('sum1c');
1016		remove_error_field('sum2c');		
1017		
1018        $.ajax({
1019            type: "POST",
1020            url: "https://yzex.co/premium_site_action-exchange_calculator.html?meth=post&yid=b97aa029cc88&ynd=0&lang=en",
1021            data: param,
1022	        dataType: 'json',
1023 			error: function(res, res2, res3) {
1024				        for (key in res) {
1025        console.log(key + ' = ' + res[key]);
1026        }
1027        			},           
1028			success: function(res) { 
1029			
1030				var changed = res['changed'];
1031			
1032				if (dej !== 1 || changed == 1) {
1033					calc_set_value('input.js_sum1', res['sum1']);
1034				}
1035				
1036				if (dej !== 2 || changed == 1) {
1037					calc_set_value('input.js_sum2', res['sum2']);	
1038				}
1039				
1040				if (dej !== 3 || changed == 1) {
1041					calc_set_value('input.js_sum1c', res['sum1c']);
1042				}
1043				
1044				if (dej !== 4 || changed == 1) {
1045					calc_set_value('input.js_sum2c', res['sum2c']);
1046				}
1047
1048				calc_set_html('.js_sum1_html', res['sum1']);
1049				calc_set_html('.js_sum2_html', res['sum2']);
1050				calc_set_html('.js_sum1c_html', res['sum1c']);
1051				calc_set_html('.js_sum2c_html', res['sum2c']);								
1052				
1053				$('.js_comis_text1').html(res['comis_text1']);
1054				$('.js_comis_text2').html(res['comis_text2']);				
1055				
1056				if (res['error_fields']) {
1057					$.each(res['error_fields'], function(index, value) {
1058						add_error_field(index, value);
1059					});					
1060				}				
1061				
1062				if (res['course_html'] && res['course_html'].length > 0) {
1063					$('.js_course_html').html(res['course_html']);
1064					$('input.js_course_html').val(res['course_html']);
1065				}			
1066				
1067				if (res['reserve_html'] && res['reserve_html'].length > 0) {
1068					$('.js_reserve_html').html(res['reserve_html']);
1069					$('input.js_reserve_html').val(res['reserve_html']);
1070				}
1071				
1072				if (res['user_discount'] && res['user_discount'].length > 0) {
1073					$('.js_direction_user_discount').html(res['user_discount']);
1074					$('input.js_direction_user_discount').html(res['user_discount']);
1075				}	
1076				
1077				if (res['viv_com1'] && res['viv_com1'] == 1) {
1078					$('.js_viv_com1').show();
1079				} else {
1080					$('.js_viv_com1').hide();
1081				}
1082				
1083				if (res['viv_com2'] && res['viv_com2'] == 1) {
1084					$('.js_viv_com2').show();
1085				} else {
1086					$('.js_viv_com2').hide();
1087				}			
1088
1089						if (res['ncapt1']) {
1090			$('.captcha1').attr('src', res['ncapt1']);
1091		}
1092		
1093		if (res['ncapt2']) {
1094			$('.captcha2').attr('src', res['ncapt2']);
1095		}
1096		
1097		if (res['nsymb']) {
1098			$('.captcha_sym').html(res['nsymb']);
1099		}	
1100		
1101		$('.captcha_value').val('');
1102if ($('.verifybysum').length > 0) {
1103	if (res['sum1']) {
1104		var verifybysum = $('.verifybysum').val().replace(/,/g, '.');
1105		verifybysum = verifybysum * 1;
1106		var res_sum1 = res['sum1'] * 1;
1107		if (res_sum1 >= verifybysum) {
1108			$('.verifybysum_wrap').show();
1109			add_error_field('sum1', 'pass identity verification');
1110			add_error_field('sum2', 'pass identity verification');
1111			add_error_field('sum1c', 'pass identity verification');
1112			add_error_field('sum2c', 'pass identity verification');
1113		} else {
1114			$('.verifybysum_wrap').hide();				
1115		}
1116	}
1117}
1118				
1119				$('.exch_ajax_wrap_abs, .js_exchange_widget_abs, .js_loader').hide();
1120            }
1121		});	
1122		
1123	}
1124
1125	
1126	$(document).ChangeInput({ 
1127		trigger: '.js_sum1',
1128		changetime: '1600',
1129		success: function(obj) {
1130			go_calc(obj, 1);
1131		}
1132	});
1133
1134	$(document).ChangeInput({ 
1135		trigger: '.js_sum2',
1136		changetime: '1600',
1137		success: function(obj) {
1138			go_calc(obj, 2);
1139		}
1140	});
1141
1142	$(document).ChangeInput({ 
1143		trigger: '.js_sum1c',
1144		changetime: '1600',
1145		success: function(obj) {
1146			go_calc(obj, 3);
1147		}
1148	});
1149
1150	$(document).ChangeInput({ 
1151		trigger: '.js_sum2c',
1152		changetime: '1600',
1153		success: function(obj) {
1154			go_calc(obj, 4);
1155		}
1156	});
1157	
1158	$(document).on('change','.js_changecalc',function() {
1159		go_calc($('.js_sum1'), 1);
1160	});		
1161
1162	function set_input_decimal(obj) {
1163		
1164		var dec = obj.attr('data-decimal');
1165		var sum = obj.val().replace(new RegExp(",",'g'), '.');
1166		var len_arr = sum.split('.');
1167		var len_data = len_arr[1];
1168		if (len_data !== undefined) {
1169			var len = len_data.length;
1170			if (len > dec) {
1171				var new_data = len_data.substr(0, dec);
1172				obj.val(len_arr[0] + '.' + new_data);
1173			}
1174		}	
1175		
1176	}	
1177	
1178	$(document).on('change', '.js_decimal', function() {
1179		set_input_decimal($(this));
1180	});
1181
1182	$(document).on('keyup', '.js_decimal', function() {
1183		set_input_decimal($(this));
1184	});
1185	
1186	});	
1187	jQuery(function($) {
1188		
1189		$('.widget_reserv_filter').on('click', function() {
1190			$('.widget_reserv_filter').removeClass('current');
1191			$(this).addClass('current');
1192			var id = $(this).attr('data-id');
1193			$('.widget_reserv_vt').hide();
1194			$('.widget_reserv_vt_' + id).show();
1195		
1196			return false;
1197		});	
1198		
1199	});
1200	

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.