PageSourceSearch

https://assets.indavideo.hu//js/src/upload.js?v=20261002-31afd2d2

js indavideo.hu collected 2026-10-02 04:43:12 UTC 29,999 bytes, 959 lines download raw bytes

1var x;
2var upload_started = 0;
3var upload_done = 0;
4var upload_firstCheck = 1;
5var uploadFinished = 0;
6var formPollerIsPolling = 0;
7var formIsSubmitting = 0;
8
9function cancelUpload() {}
10
11function ChangePublicate(value){
12		    if ($(".publicate_btn.opened").length != 0 || value.target == undefined){
13				if (value.target != undefined)
14				{
15					    if ($(this).text() == "publikus") {
16					        $('#isPrivate').val(0);
17					        $('#isUnlisted').val(0);
18					} else if ($(this).text() == "nem listázott") {
19					    $('#isPrivate').val(0);
20					    $('#isUnlisted').val(1);
21					} else if ($(this).text() == "privát") {
22					    $('#isPrivate').val(1);
23					    $('#isUnlisted').val(0);
24					}
25					$(this).addClass('active');
26					$(".publicate_btn").each(function() {
27					     if (!$(this).hasClass('active'))
28					         $(this).css("display","none");
29					});
30				} else {
31					if (value == "public") {
32					    $('#isPrivate').val(0);
33					    $('#isUnlisted').val(0);
34					} else if (value == "unlisted") {
35						$('#isPrivate').val(0);
36						$('#isUnlisted').val(1);
37					} else if (value == "private") {
38						$('#isPrivate').val(1);
39						$('#isUnlisted').val(0);
40			        }
41					var elem = $('.publicate_btn' + '[data-value="' + value + '"]');
42					$('.publicate_btn').removeClass('active');
43					$(elem).addClass('active');
44				    $('.publicate_btn').each(function() {
45				         if (!$(this).hasClass('active'))
46				             $(this).css("display","none");
47				         else
48				             $(this).css("display","block");
49				    });
50				}
51			} //if
52		    if (value.target != undefined && !$("body").hasClass('input_disabled')) {
53				if ($(".publicate_btn.opened").length == 0) {
54					$(this).addClass('opened');
55					$('.publicate_btn').css("display","block").removeClass('active');
56				} else {
57				    $('.publicate_btn').removeClass("opened");
58				}
59			}
60}
61
62$(document).ready(function () {
63
64	$('.txt-i-want-to-be-a-superuser').click(function(){
65		var superMsg = $(this).children('.iwanttobesuper-msg').html();
66		proModal();
67		return false;
68	});
69
70	$("#upload #passwordProtected").click(function() {
71		if ($(this).is(":checked")) {
72			$("#publ_btn_priv.publicate_btn").trigger('click').trigger('click');
73		}
74	});
75
76	$("#savepreset_chkbx").on("click",function(e){
77	//	e.preventDefault();
78	//	e.stopImmediatePropagation();
79
80	console.log(e, !$('#savepreset_chkbx').is(":checked"));
81		if ($('#savepreset_chkbx').is(":checked")) {
82			$('#zone-presetitle').show();
83		} else {
84			$('#zone-presetitle').hide();
85		}
86	});
87	$(document).on("click","#upload .preset_select",function(e) {
88		e.preventDefault();
89		e.stopImmediatePropagation();
90
91		if ($(".preset_select.opened").length != 0) {
92			// json adat lekerdezes
93			// @todo eltarolni
94		  var items = [];
95
96var selected_preset_id = $(this).data("value");
97$.getJSON( "/?getpreset=1", function( presets ) {
98
99		$.each(presets[selected_preset_id], function(index,val) {
100						    switch (index) {
101						        case "title":
102					  				if (val != "")
103						                $('.title').val(val);
104							        break;     
105						        case "description":
106						       
107						            if (val != "")
108						                $('#descriptionField').val(val);
109							        break;  
110											        
111						        case "tag":
112						            //$('#tags').val(val);
113											            
114						            if (val != "")
115						                if ($('#tags').val() != "")
116						                    $('#tags').val($('#tags').val()+", "+val);
117						                else
118						                    $('#tags').val(val);
119							        break;
120											        
121						        case "radio":
122						            $('radio_input[value=' + val +' ]').prop("checked", true);
123						            if (val == "39")
124						                $('#felnott_tartalom').prop("checked",pu.presetData[preset]['ageLimit']);
125							        break;
126						        case "ageLimit":
127						            $('#felnott_tartalom').prop("checked",val);
128						            break;
129							    case "status_video":
130							        switch(val){
131								       case '-10':
132								       val = 'private';
133								 	   break;
134									   case '-1':
135									   		val = 'unlisted';
136								   	   	break;
137								       case '1':
138										  val = 'public';
139									      break;
140							        } //switch
141							        ChangePublicate(val);
142								    break;
143								 default: break;
144							 }   
145				}); 
146			
147});
148			$(this).addClass('active');
149			$('#id_preset').val(selected_preset_id);
150			$(".preset_select").each(function() {
151				if (!$(this).hasClass('active'))
152					$(this).hide();
153			});
154		}
155
156		if ($(".preset_select.opened").length == 0) {
157			$(this).addClass('opened');
158			$(".preset_select").css("display","block").removeClass('active');
159			// console.log("opened");
160		}
161		else {
162			$(".preset_select").removeClass("opened");
163			// console.log("nincs");
164		}
165
166	});
167
168
169	$(document).on("click","#upload .publicate_btn",function(e) {
170		e.preventDefault();
171		e.stopImmediatePropagation();
172
173		if ($(".publicate_btn.opened").length != 0) {
174			if ($(this).text() == "publikus") {
175				$("#isPrivate").val(0);
176				$("#isUnlisted").val(0);
177			}
178			else if ($(this).text() == "nem listázott") {
179				$("#isPrivate").val(0);
180				$("#isUnlisted").val(1);
181			}
182			else if ($(this).text() == "privát") {
183				$("#isPrivate").val(1);
184				$("#isUnlisted").val(0);
185			}
186			$(this).addClass('active');
187			$(".publicate_btn").each(function() {
188				if (!$(this).hasClass('active'))
189					$(this).hide();
190			});
191
192            if ($(".palyazat_publikalas").length > 0) {
193                if ($("#isPrivate").val() == 1 || $("#isUnlisted").val() == 1) {
194                    msgOk("Nem lehet nem publikus a pályázati anyagod!","Ha részt szeretnél venni a pályázatunkon, nem állíthatod nem publikusra a videódat. A kapcsolót automatikusan visszállítottuk publikusra.");
195
196                    $("#isPrivate").val(0);
197                    $("#isUnlisted").val(0);
198
199                    $(".publicate_btn").removeClass('active');
200                    $("#publ_btn_pub").addClass('active').show();
201                    $(".publicate_btn").each(function() {
202                        if (!$(this).hasClass('active'))
203                            $(this).hide();
204                    });
205                }
206            }
207			// console.log("vált");
208		}
209
210		if ($(".publicate_btn.opened").length == 0) {
211			$(this).addClass('opened');
212			$(".publicate_btn").css("display","block").removeClass('active');
213			// console.log("opened");
214		}
215		else {
216			$(".publicate_btn").removeClass("opened");
217			// console.log("nincs");
218		}
219
220	});
221
222	$('input#passwordProtected').change (function () {
223		if ($('#passwordProtected:checked').length == 0)
224			$('.password-min-length .input').hide();
225		else
226			$('.password-min-length .input').show();
227	});
228
229	$('input#addSubtitle').change (function () {
230		if ($('#addSubtitle:checked').length == 0)
231			$('.subtitle-upload .input').hide();
232		else
233			$('.subtitle-upload .input').show();
234	});
235
236	$('#upload_subtitle_btn').change(function(){ uploadHandler.onUploadSubtitle(this);});
237    
238//	$('#titleField').change(function(){ checkTitle($(this).val());});
239	tabTab.bind();
240
241	$('div.controllButtons a.confirm').click(function (e) {
242		e.preventDefault();
243		$('#btn_upload').css("display", "none");
244		myConfirm("Biztos hogy megszakítod a feltöltést?", "Feltöltés megszakítása", function () {
245			window.location.href = '/';
246		});
247	});
248
249	$('div.controllButtons a.submit').click(function (e) {
250		return uploadHandler.formSubmitHandler();
251	});
252
253	channelChangedHandler ();
254
255	// $("#tags").autocomplete("/acomplete.php", {
256	// 	width: 360,
257	// 	max: 8,
258	// 	minChars: 2,
259	// 	highlight: false,
260	// 	multiple: true,
261	// 	multipleSeparator: ",",
262	// 	scroll: true,
263	// 	scrollHeight: 300,
264	// 	selectFirst: false
265	// });
266
267	if ($("input.castrole").length) {
268	$("input.castrole").autocomplete("/acomplete.php", {
269		width: 170,
270		max: 8,
271		minChars: 2,
272		highlight: false,
273		multiple: true,
274		multipleSeparator: " ",
275		scroll: true,
276		scrollHeight: 300
277	});
278	}
279	$("#upload .channel_selector span.erotika input").change (function () {
280		erotikaChecked = $(this).attr('checked');
281		age_limitChecked = $("input#age_limit").attr('checked');
282		if ((erotikaChecked && !age_limitChecked) ||
283			(!erotikaChecked && age_limitChecked))
284			$("input#age_limit").check();
285		});
286	$("input#age_limit").change (function () {
287		erotikaChecked = $("#upload .channel_selector span.erotika input").attr('checked');
288		age_limitChecked = $("input#age_limit").attr('checked');
289		if (erotikaChecked && !age_limitChecked)
290			$("input#age_limit").check();
291		});
292});
293
294function proModal () {
295	title = '';
296	message = $('.iwanttobesuper-msg').html();
297	if (typeof(title) != 'undefined')
298		$('#confirm').modal ({
299			closeHTML:"<a href='#' title='Bezár' class='modal-close'>x</a>",
300			overlayId: 'modal-overlay',
301			containerId: 'modal-container-pro',
302			onShow: function (dialog) {
303
304				var newPos = $('#modal-container-pro').position();
305				newPos.left = Math.floor(($(window).width() / 2) - ($('#modal-container-pro').width() / 2));
306				newPos.top = "20%";
307
308				$('#modal-container-pro').css(newPos);
309				$('#alert .message').html(message);
310
311				/*
312				if (typeof(title) != 'undefined')
313					$('#alert h1').html (title);
314				$('#alert .message').html(message);
315				*/
316				$('#confirm .message').html(message);
317				$('.yes').click(function () {
318					if ($.isFunction(proWannaBe)) {
319						proWannaBe();
320					}
321				});
322				$('.no').click(function () {
323					if ($.isFunction(callbackIfNo))
324						callbackIfNo.apply();
325					$.modal.close();
326				});
327			}
328		});
329		return false;
330	}
331
332function alert(message) {
333	return myAlert (message, 'Jaj...');
334}
335
336var tabTab = {
337
338	current_step: "basic_data",
339	current_fading: new Array(),
340
341	bind: function(){
342		$("#stepbar div").not(".separator").click(function() {
343			tabTab.toggle(this);
344		});
345	},
346	toggle: function(id){
347
348		var DEBUGMODE = false;
349
350		if (!DEBUGMODE && !upload_started && ($(id).attr("id") != "basic_data")) {
351			myAlert('A feltöltés megkezdése után érhető csak el!', 'Hiba!');
352			return;
353			}
354
355		switch (this.current_step) {
356			case 'basic_data':
357				if (!jQuery.trim($("#titleField").val()).length) {
358					setInputzoneError ("#zone-title", 'kotelezo');
359					}
360					
361				else if (!checkTitle($("#titleField").val())) {
362					setInputzoneError ("#zone-title", 'invalid');
363				}
364				else if ($("#titleField").parent().hasClass('errorous'));
365				else
366					setInputzoneError ("#zone-title", false);
367
368/*				if (!jQuery.trim($("#descriptionField").val()).length)
369				{
370					setInputzoneError ("#zone-description", true);
371				}
372				else
373					setInputzoneError ("#zone-description", false);
374*/
375				if ($("#tags-hidden-finaltags").length !== 0) {
376					var tags_exp = jQuery.trim($("#tags-hidden-finaltags").val()).split(",");
377
378					if (tags_exp.length < 2) {
379						setInputzoneError ("#zone-tags", 'kotelezo');
380					}
381					else {
382						setInputzoneError ("#zone-tags", false);
383					}
384				}
385				else {
386					if (!jQuery.trim($("#tags").val()).length) {
387						setInputzoneError ("#zone-tags", 'kotelezo');
388					}
389					else {
390						setInputzoneError ("#zone-tags", false);
391					}
392				}
393
394				if (!checkTitle($("#tags").val())) {
395                                        setInputzoneError ("#zone-tags", 'charerror');
396                                }
397
398				if (!$("#zone-channel input:checked").size())
399					setInputzoneError ("#zone-channel", 'kotelezo');
400				else
401					setInputzoneError ("#zone-channel", false);
402				break;
403			case 'publicate':
404				var pw1 = $("#passwordProtectedField").val();
405				var pw2 = $("#passwordProtectedField2").val();
406				if ($("#passwordProtected").attr("checked")) {
407					if (!pw1.length || !pw2.length)
408						setInputzoneError ("#zone-password", "miss");
409					else if (pw1 != pw2)
410						setInputzoneError ("#zone-password", "match");
411					else if (pw1.length < 6)
412						setInputzoneError ("#zone-password", "len");
413					}
414
415				if (!$("#upload-timing-date-now").attr("checked")) {
416					var pubYear = parseInt($("#upload-timing-date-year").val(), 10);
417					var pubMonth = parseInt($("#upload-timing-date-month").val(), 10);
418					var pubDay = parseInt($("#upload-timing-date-days").val(), 10);
419					var pubHour = parseInt($("#upload-timing-date-hours").val(), 10);
420					var pubMin = parseInt($("#upload-timing-date-mins").val(), 10);
421					var pubDate = new Date(pubYear,pubMonth-1,pubDay+1,0,0,0,0);
422					var currDate = new Date();
423					if (pubDate < currDate)
424						setInputzoneError ("#zone-timing", true);
425					else
426						setInputzoneError ("#zone-timing", false);
427					}
428				break;
429			}
430
431		if (!DEBUGMODE && $("#cnt_" + this.current_step).find("div.input.errorous").size())
432			return false;
433
434		if (upload_started || DEBUGMODE) {
435			var toFadeOut = this.current_step;
436			this.current_fading[toFadeOut] = toFadeOut;
437			this.current_step = $(id).attr("id");
438			$("#cnt_" + toFadeOut).fadeOut(100, function(){ $("#cnt_" + tabTab.current_step).fadeIn(100); });
439
440			if ((this.current_fading[this.current_step] != "") && (this.current_fading[this.current_step] != undefined) ){
441				var id_selected = "#" + this.current_fading[this.current_step] + " > #selected";
442				var id_unselected = "#" + this.current_fading[this.current_step] + " > #unselected";
443				$(id_selected).stop(true, true);
444				$(id_unselected).stop(true, true);
445			}
446
447			if (this.current_fading[toFadeOut] != this.current_step){
448				tabTab.fadeTabOut(toFadeOut);
449				tabTab.fadeTabIn(this.current_step);
450			}
451			switch (this.current_step) {
452				case 'basic_data':
453					_gaq.push(['_trackPageview', '/step1']);
454					break;
455				case 'publicate':
456					_gaq.push(['_trackPageview', '/step2']);
457					break;
458				case 'extras':
459					_gaq.push(['_trackPageview', '/step3']);
460					break;
461			}
462		}
463	},
464	fadeTabIn: function(id){
465		var id_selected = "#" + id + " > #selected";
466		var id_unselected = "#" + id + " > #unselected";
467		$(id_unselected).css({'margin-left' : "-" + $(id_selected).width()  + "px" });
468		$(id_unselected).fadeOut(250, function(){ $(id_selected).css({'margin-left' : '0px'}) } );
469		$(id_selected).fadeIn(250);
470	},
471	fadeTabOut: function(id){
472		var id_selected = "#" + id + " > #selected";
473		var id_unselected = "#" + id + " > #unselected";
474		$(id_unselected).css({'margin-left' : "-" + $(id_unselected).width()  + "px" });
475		$(id_selected).fadeOut(2000, function(){ $(id_unselected).css({'margin-left' : '0px'}); } );
476		$(id_unselected).fadeIn(2000, function(){ tabTab.current_fading[id] = ""; });
477	}
478}
479
480function checkTitle(title) {
481    var regex = new RegExp("^[a-zA-Z0-9 áéíóöőúüűÁÉÍÓÖŐÚÜŰ()<>:,.;!'-_|+#&=]+$");
482    if (regex.test(title)) {
483	return true;
484    } else {
485	return false;
486    }
487}
488
489function setDateNowPicker (mode) {
490	var container = $("div.datepicker");
491	var checkEl = container.children ("label").children("input");
492	if ((checkEl.attr('checked') || (mode===true)) && (mode!=false)) {
493		container.children ('select').attr("disabled", true);
494		checkEl.setChecked();
495	}
496	else {
497		container.children ('select').attr("disabled", false);
498		checkEl.setUnchecked();
499	}
500}
501
502function  proWannaBe() {
503		var user_id = $("#modal-container-pro #userid").val();
504		var htmlText = '<span class="answer" style="color: #000; font-size: 12px;">Kérésedet rögzítettük, rövidesen jelentkezünk.</span> <span class="closepro" onclick="$.modal.close();return false;" style="color: #000; font-size: 12px; font-weight: bold; cursor: pointer;">Bezárom</span>';
505		
506		_gaq.push(['_trackPageview', '/prowannabe_clicked']);
507
508		if (!GetCookie('prowannabe')) {
509			setCookie( 'prowannabe', 1, 7, '/', 'indavideo.hu' , false );
510			$.ajax ({
511				url: '/upload.php/prowannabe',
512				data: {
513					uid: user_id
514					},
515				cache: false,
516				type: 'POST',
517				success: function () {
518						$('#modal-container-pro .buttons').css ("width", "300px");
519	 			        $('#modal-container-pro .buttons').html(htmlText);
520					}
521			});
522		}
523		else {
524			$('#modal-container-pro .buttons').css ("width", "300px");
525	        $('#modal-container-pro .buttons').html(htmlText);
526		}
527	}
528
529var uploadHandler = {
530
531	sCSRFUpload : "#CSRF_upload",
532	sHTMLUploadForm : "#form1Frame",
533	sSWFUObject : "#SWFUpload_0",
534
535	progressUpdateLast: 0,
536
537	uploadStart: function(file) {
538		_gaq.push(['_trackPageview', '/file_upload_started']);
539		$("#video_edit .save_buttons .btn").toggle();
540		return true;
541	},
542	
543	fileQueued: function(file)
544	{
545		if (! $('input#titleField').val())
546			$('input#titleField').val(file.name.replace(/\..*?$/,''));
547	},
548	fileDialogComplete: function(numFilesSelected, numFilesQueued) {
549		//console.log ('fileDialogComplete');	console.log (numFilesSelected);	console.log (numFilesQueued);
550		try {
551			if ((numFilesSelected > 0) && (numFilesQueued > 0)) {
552				//document.getElementById(this.customSettings.cancelButtonId).disabled = false;
553				this.startUpload();
554				document.getElementById("SWFUpload_0").style.width = "1px";
555				document.getElementById("SWFUpload_0").style.height = "1px";
556				document.getElementById("upload_bar_progress").style.display = "block";
557				}
558		} catch (ex)  {};
559	},
560	
561	onUploadSubtitle: function(form) {
562	    var self = uploadHandler;
563	    console.log('up srt');	    
564    	    var file = form.files[0];
565    	    if (file) {
566        	var name = file.name;
567        	var size = file.size;
568        	var type = file.type;
569        	$(".add_subtitle").removeClass("error");
570        	$(".add_subtitle").removeClass("error_file");
571        	$(".add_subtitle").removeClass("error_missing");
572        	var formData = new FormData($('form')[0]);
573        	$.ajax({
574            	    url: '/uploadsubtitle.php',
575            	    type: 'POST',
576            	    xhr: function() {
577            		var myXhr = $.ajaxSettings.xhr();
578            		if(myXhr.upload){
579            		    myXhr.upload.addEventListener('progress',uploadHandler.progressHandlingSubtitle, false);
580            		}
581            		return myXhr;
582        	    },
583        	    beforeSend: uploadHandler.beforeSendHandlerSubtitle,
584        	    success: uploadHandler.completeHandlerSubtitle,
585        	    error: uploadHandler.errorHandlerSubtitle,
586        	    data: formData,
587        	    cache: false,
588        	    contentType: false,
589        	    processData: false
590        	});
591    	    }
592	},
593	progressHandlingSubtitle: function(e){
594	    if(e.lengthComputable){
595        	$('progress').attr({value:e.loaded,max:e.total});
596    	    }
597        },
598        beforeSendHandlerSubtitle: function(e) {
599        },
600        errorHandlerSubtitle: function(e) {
601        },
602	completeHandler: function(e) {
603        data = JSON.parse(e)
604        if (data.success != 1 ) {
605            switch(data.error) {
606                case "toolarge":
607                    $(".add_subtitle").addClass("error_filesize");
608                    break;
609                case "invalidtype":
610                    $(".add_subtitle").addClass("error_file");
611                    break;
612                case "nofile":
613                    $(".add_subtitle").addClass("error_missing");
614                    break;
615                default:
616                    $(".add_subtitle").addClass("error_uni");
617            }
618        } else {
619            $(".add_subtitle").addClass("active");
620            $("#upload-subtitle span.title").html(data.filename);
621            $("#audioHash").val(data.filehash);
622            $("#upload_music_btn").attr('disabled',true);
623            $(".add_subtitle span.icon").click(function(){
624                customAudio.fileid++;
625                var ahash = $("#audioHash").val();
626                $("#upload-subtitle").val("");
627                $("#upload_music_btn").attr('disabled',false);
628                $(".add_subtitle").removeClass("active");
629    //            $("#audiotrack span.title").html("Hangsáv feltöltése");
630            });
631        }
632    	},
633
634                                                                          
635	swfuLoadError: function() {
636		var self = uploadHandler;
637
638		if (($(self.sSWFUObject).length == 0 || !$(self.sSWFUObject).is(":visible")) && !$(self.sHTMLUploadForm).is(":visible"))
639		{ // nem töltött be a gomb, de a html-form sem látszik
640			$.ajax({
641				url: "/",
642				type: 'POST',
643				dataType: 'json',
644				data: {
645					op: 'swfuLoadError',
646					CSRF: $(self.sCSRFUpload).val(),
647					error: "dont_load"
648				},
649				success: function(data) {
650					
651				}
652			});
653
654			msgOk('Miért nem megy ez a fránya feltöltés?', 
655			      'Talán nincs <a href="https://indavideo.hu/faq#ans-mi-az-a-flash-a-html5-etel-vagy-ital" target="_blank">Flash</a> a gépeden. Vagy adblock-ot használsz, amit a feltöltéskor kapcsolj ki.<br>De lehet, hogy elég csak újratöltened ezt az oldalt.',
656			      "",
657			      function() {
658			      	$.ajax({
659						url: "/",
660						type: 'POST',
661						dataType: 'json',
662						data: {
663							op: 'swfuLoadError',
664							CSRF: $(self.sCSRFUpload).val(),
665							error: "modal_click"
666						},
667						success: function(data) {
668							
669						}
670					});
671			      });
672
673		}
674	},
675	uploadProgress: function(file, bytesLoaded, bytesTotal) {
676		//console.log ('uploadProgress');
677		try {
678			var percent = Math.ceil((bytesLoaded / bytesTotal) * 100);
679			var progress = new FileProgress(file, this.customSettings.progressTarget);
680			progress.setProgress(percent);
681			progress.setStatus("Uploading...");
682
683			uploadHandler.updateDisplay.call(this, file);
684
685		} catch (ex) {}
686	},
687	
688        uploadError: function(file, errorCode, message) {
689		$.ajax({
690			url: "/",
691			type: 'POST',
692			dataType: 'json',
693			data: {
694				op: 'swfuLoadError',
695				CSRF: $(self.sCSRFUpload).val(),
696				error: "upload_error",
697				ecode: errorCode,
698				filename: file,
699				msg: message
700			},
701			success: function(data) {
702			}
703	    });        
704	},
705	uploadSuccess: function(file, serverData) {
706		var data = null;
707		try {
708			if (data = $.parseJSON(serverData.substring (1,serverData.length-1)))
709				if (data.success == "1") {
710					upload_done = 1;
711					//return uploadHandler.handleNewThumbnails(serverData);
712					_gaq.push(['_trackPageview', '/file_upload_success']);
713
714					uploadHandler.checkFile();
715					uploadHandler.regenerate ();
716					$("#upload_bar_progress div.txt-upload_info").hide ();
717					$("#upload_bar_progress div.success").show ();
718					return;
719					}
720			}
721		catch (e) { }
722		// ide csak hibánál jut
723		$("#upload_bar_progress div.txt-upload_info").hide ();
724		$("#upload_bar_progress div.error").show ();
725		return;
726	},
727	uploadComplete: function(file) {
728		//console.log ('uploadComplete');console.log (file);
729		//upload_done = 1;
730		//return uploadHandler.handleNewThumbnails(serverData);
731		_gaq.push(['_trackPageview', '/upload_complete']);
732		$("#video_edit .save_buttons .btn").toggle();
733	},
734	updateDisplay: function(file) {
735		//console.log ('updateDisplay');
736		var ts = Math.round(new Date().getTime() / 1000);
737		if (this.progressUpdateLast == 0)
738			this.progressUpdateLast = ts;
739		else if ((this.progressUpdateLast + 1) > ts)
740			return;
741
742		this.progressUpdateLast = ts;
743
744		this.customSettings.tdTimeRemaining.innerHTML = SWFUpload.speed.formatTime(Math.floor(file.timeRemaining));
745	},
746	checkFile: function()
747	{
748		var hash = $("#upload-video-hash").val();
749		$.ajax({
750			url: '/upload.php/checkfile',
751			data: { FILE_HASH: hash },
752			cache: false,
753			type: 'POST',
754			success: function(d, status)
755			{
756				//console.log(d);
757			}
758		});
759	},
760	regenerate: function() {
761		if (formPollerIsPolling)
762			return;
763		//console.log ('regenerate');
764		$("#cnt_publicate div.afterUpload").add ("#cnt_publicate #thumbnails").addClass ("HIDED");
765		$("#cnt_publicate div.beforeUpload").removeClass ("HIDED");
766		var hash = $("#upload-video-hash").val();
767		$.ajax({
768			url: '/upload.php/generate',
769			data: { FILE_HASH: hash },
770			cache: false,
771			type: 'POST',
772			success: function(serverData, status) {
773				if (serverData == '')
774					return false;
775				else
776					return uploadHandler.handleNewThumbnails (serverData);
777				}
778			});
779	},
780	handleNewThumbnails: function (serverData) {
781		try {
782			var response = eval(serverData);
783
784			if ((typeof(response.success)=='undefined') || (response.success!=1)) {
785				//console.log ('nincs');
786				if (typeof(response.errorMsg)!='undefined')
787					alert (response.errorMsg, 'Hiba a feltöltésnél');
788				else
789					alert('Ismeretlen hiba!', 'Hiba a feltöltésnél!');
790			}
791	//		else if ((typeof(response.thumbnails)=='undefined') || !response.thumbnails.length)
792	//			alert('A kisképeket nem sikerült létrehozni. Valószínüleg ismeretlen formátumot töltöttél fel.', 'Hibás a file?');
793			else {
794				//console.log ('OK');
795				$('#cnt_publicate div.beforeUpload').addClass('HIDED');
796				$('#cnt_publicate div.afterUpload').add ("#cnt_publicate #thumbnails").removeClass('HIDED');
797				var ul = $('ul#thumbnails');
798				ul.children('li').not('.dummy').not('.regenerate').remove();
799				var genEl = ul.children('li.regenerate');
800				genEl.removeClass('HIDED');
801				var isFirst=true;
802				for (i in response.thumbnails) {
803					//console.log (response.thumbnails[i]);
804					var newEl = $('ul#thumbnails li.dummy').clone();
805					newEl.children("img").attr('src', response.thumbnails[i] + '?' + Math.round(10000000000*Math.random()));
806					if (isFirst) {
807						newEl.addClass ('selected');
808						$("#upload-thumb-fname").val(newEl.children("img").attr('src'));
809						isFirst = false;
810						}
811						// @removeme
812					genEl.before(newEl);
813					newEl.removeClass('dummy');
814					newEl.click(function(){ uploadHandler.handleThumbnailClick(this); });
815					}
816				$("#upload-thumb-fname").val("");
817			}
818		} catch (ex) {
819//			alert('Ismeretlen hiba2','Hiba a feltöltésnél');
820		};
821	},
822	handleThumbnailClick: function(el) {
823		var imgEl = $(el).children('img');
824		imgEl.parent().siblings().not('.dummy').not('.regenerate').removeClass('selected').addClass('unselected');
825		$("#upload-thumb-fname").val(imgEl.attr('src'));
826		imgEl.parent().removeClass('unselected').addClass('selected');
827		return false;
828	},
829	setErrorousForm: function() {
830		$("#form1Frame").remove();
831		upload_started=1;
832		upload_done=1;
833		uploadHandler.regenerate ();
834	},
835	swfLoaded: function () {
836		$("#form1Form").remove();
837		uploadHandler.swfuLoadError();
838	},
839	form1Changed: function () {
840		if (upload_firstCheck) {
841			upload_firstCheck = 0;
842			return;
843			}
844		upload_started = 1;
845		upload_done = 1;
846		uploadHandler.regenerate();
847	},
848	formSubmitHandler: function () {
849	// itt kell leellenorizni a szukseges mezoket! title, description, tag
850
851		if (formIsSubmitting)
852			return;
853
854		//if (!upload_done) {
855		//	return myAlert('Még nem töltődött fel a videófájlod, kis türelmet kérünk', 'Még tart a feltöltés.');
856		//}
857
858		var divEls = $("#cast input:not(.default)").add("#music input:not(.default)");
859		var errorousDivs = divEls.filter("input[value='']").addClass("errorous");
860
861		var adcheckBoxEls = $(".adstatements  input");
862		var errorousadcheckBoxs = adcheckBoxEls.filter("input[checked!='checked']").addClass("errorous")
863		if (errorousadcheckBoxs.size() >= 2 ) {
864			$(".adstatements").addClass("errorous");
865		} else {
866			$(".adstatements").removeClass("errorous");
867		}
868		$(".adultst").removeClass("errorous");
869		$(".copyst").removeClass("errorous");
870
871		var checkBoxEls = $(".statements  input");
872		var errorouscheckBoxs = checkBoxEls.filter("input[checked!='checked']").addClass("errorous")
873		for (var e=0; e<errorouscheckBoxs.size(); e++) {
874			var parentdiv = errorouscheckBoxs[e].parentNode;
875			$(parentdiv).addClass("errorous");
876		}
877		if ( errorouscheckBoxs.size() || errorousDivs.size() || errorousadcheckBoxs.size() == 2 )
878		{
879
880
881			return;
882		}
883
884		if (!upload_done) {
885			//return myAlert('Még nem töltődött fel a videófájlod, kis türelmet kérünk', 'Még tart a feltöltés.');
886			formPollerIsPolling = 1;
887			uploadHandler.uploadFormPoller();
888			myAlert (
889				"Hagyd nyitva ezt az ablakot, hogy ne szakadjon meg a folyamat, de közben nyugodtan csinálhatsz valami hasznosat egy másikban. Aztán majd nézz vissza pár perc múlva.",
890				"Még tart a feltöltés",
891				function() {
892					formPollerIsPolling = 0;
893					$.modal.close();
894				});
895			return;
896		}
897
898		myAlert ("Dolgozom...", "kis türelmet...");
899		return uploadHandler.formSubmitter ();
900	},
901	uploadFormPoller: function () {
902		if (!formPollerIsPolling)
903			return;
904		if (upload_done) {
905			return uploadHandler.formSubmitter();
906			}
907		setTimeout ("uploadHandler.uploadFormPoller();", 2000);
908	},
909	formSubmitter: function () {
910		if (formIsSubmitting)
911			return;
912		formIsSubmitting = true;
913		$("#cast input.default")
914			.add("#music input.default")
915			.add("#additional-new input.default")
916			.val('');
917		$('form#upload-form').submit();
918		_gaq.push(['_trackPageview', '/form_submitted']);
919
920	},
921	updateNotifyOnComplete: function () {
922		var hash = $("#upload-video-hash").val();
923		$.ajax ({
924			url: '/upload.php/notify',
925			data: {
926				FILE_HASH: $("#upload_FILE_HASH").val(),
927				notify: $("#notifyOnComplete").attr("checked") ? 'on' : ''
928				},
929			cache: false,
930			type: 'POST',
931			success: function () {
932				$("#uploadConvertingStatus div.option.before").hide ();
933				$("#uploadConvertingStatus div.option.after").show ();
934				}
935		});
936	}
937
938}
939
940 function getFlashVersion() {
941		if (typeof this.flashVersion != "undefined") { return this.flashVersion; }
942		var version = 0;
943		if (typeof navigator.plugins != "undefined" && typeof navigator.plugins["Shockwave Flash"] == "object") {
944			desc = navigator.plugins["Shockwave Flash"].description;
945			if (desc && !(typeof navigator.mimeTypes != "undefined" && navigator.mimeTypes["application/x-shockwave-flash"] && !navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin)) {
946				version = parseInt(desc.match(/^.*\s+([^\s]+)\.[^\s]+\s+[^\s]+$/)[1], 10);
947			}
948		} else if (typeof window.ActiveXObject != "undefined") {
949			try {
950				var testObject = new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
951				if (testObject) {
952					version = parseInt(testObject.GetVariable("$version").match(/^[^\s]+\s(\d+)/)[1], 10);
953				}
954			} catch(e) {}
955		}
956		this.flashVersion = version;
957//		console.log('Fv:'+version)
958		return version;
959}

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.