function getDays(){var a="";$.ajax({async:false,type:"GET",url:"libs/xml-processor.php?do=getDays&rand="+Math.floor(Math.random()*1000000),success:function(g){var d=0;var b=g;var f=b.split("|");while(d<f.length){tmp=f[d].split(";");a=a+"<option id='days"+d+"' value='"+tmp[0]+"|"+tmp[1]+"|"+tmp[2]+"'>"+tmp[0]+"."+tmp[1]+"."+tmp[2]+"</option>\n";tmp="";d++}$("#cal_select").empty();$("#cal_select").append(a);try{var c="#"+$("#cal_select>option:last").attr("id");$(c).attr("selected","selected")}catch(e){}intCalIndex=document.getElementById("cal_select").selectedIndex;intCalMaxIndex=document.getElementById("cal_select").length-1;getDaysImages($("#cal_select>option:last").val())}})}function getDaysImages(d){var a="";var c="";c=d;c=d.split("|");var b="";b="&day="+c[0]+"&month="+c[1]+"&year="+c[2];$.ajax({async:false,type:"GET",url:"libs/xml-processor.php?do=getDaysImages&rand="+Math.floor(Math.random()*1000000)+b,success:function(k){var f=0;var e=k;var h=e.split("|");if(h.length>0){while(f<h.length){tmp=h[f].split(";");a=a+"<option id='images"+f+"' value='"+tmp[1]+"'>"+tmp[0]+"</option>\n";tmp="";f++}$("#image_select").empty();$("#image_select").append(a);intMaxImageIndex=document.getElementById("image_select").length-1;try{if(boolFirstLoad==1){var j=$("#image_select>option:last").attr("id");$("#"+j).attr("selected","selected");boolFirstLoad++}else{if(intImageIndex>intMaxImageIndex){intImageIndex=0}var j=$("#image_select>option:eq("+intImageIndex+")").attr("id");$("#"+j).attr("selected","selected")}}catch(g){intImageIndex=document.getElementById("image_select").length+1}intImageIndex=document.getElementById("image_select").selectedIndex;if(intImageIndex<0){intImageIndex=0}playImage($("#image_select>option:eq("+intImageIndex+")").val())}}})};
