var d=document,n=navigator,l=n.userAgent.toLowerCase(),i=l.indexOf('opera'),v,isO=i!=-1,isOO=isO&&parseFloat(l.substr(i+6))<7,ie4u=(i=l.indexOf('msie'))>=0&&!isO&&d.all&&d.all.item&&(v=parseFloat(l.substr(i+5)))>=4,iebdy=ie4u&&d.compatMode=='CSS1Compat'?d.documentElement:d.body,ie5=ie4u&&v>=5,ie55=ie5&&v>=5.5,isN4=n.appName=='Netscape'&&!d.getElementById&&!isO,isMOZ=l.indexOf('gecko')!=-1,ex_tm=0,dyn=0,wonl=[],mcr=[],clc=[],CLm='',ststr='';function und(o){return typeof(o)=='undefined'||o===''||o==null};function tryex(s,t){if(!ex_tm){ex_tm=setTimeout('ex_t('+s+')',und(t)?200:t)}return false};function ex_t(s){ex_tc();eval(s)};function ex_tc(){if(ex_tm){clearTimeout(ex_tm);ex_tm=0}};function wload(){for(i in wonl)eval(wonl[i])};function winonload(s){wonl.push(s)};function gwload(){dyn=!(und(d.body)||und(d.body.innerHTML))};function selected_option(e,df){if(und(e))return und(df)?'':df;for(i=0;i<e.options.length;i++){if(e.options[i].selected)return e.options[i].value}return und(df)?'':df};function gl(i,p){var l=und(p)?document:p.document;if(und(l[i])){var j,e,c=l.layers.length;if(c==0)return;else for(j=0;j<c;j++){e=gl(i,l.layers[j]);if(!und(e))return e}}else return l[i]};function ge(i){return typeof(i)=='string'?d.getElementById?d.getElementById(i):d.all?d.all[i]:d.layers?gl(i):null:i};function ges(i){var l=ge(i);return und(l)?null:d.layers?l:l.style};function setpos(e,x,y){var s=ges(e);if(und(s))return;if(isN4)s.moveTo(x,y);else if(isOO){s.pixelLeft=x;s.pixelTop=y}else{s.left=x+'px';s.top=y+'px'}};function setvis(e,v){var s=ges(e);if(und(s))return;s.visibility=v?isN4?'show':'visible':isN4?'hide':'hidden';s.display=v?'inline':'none'};function winw(){return ie4u?iebdy.clientWidth:self.innerWidth};function winh(){return ie4u?iebdy.clientHeight:self.innerHeight};function winl(){return ie4u?iebdy.scrollLeft:self.pageXOffset};function wint(){return ie4u?iebdy.scrollTop:self.pageYOffset};function winnew(u,w,h){var ww=Math.min(winw(),und(w)?800:w),wh=Math.min(winh(),und(h)?450:h),l=und(screen)?0:Math.round((screen.width-ww)/2),t=und(screen)?0:Math.round((screen.height-wh)/2);return window.open(u,'','copyhistory=0,directories=0,location=0,menubar=0,scrollbars=0,status=0,toolbar=0,width='+ww+',height='+wh+',resizable=yes,left='+l+',top='+t)};winonload('gwload()');function DateSrc(d){if(!(typeof(d)=='object'&&d.getTime))return d;n=new Date();n.setTime(d.getTime());return n};if(!Array.prototype.push){Array.prototype.push=function(){var i,a=arguments;for(i=0;i<a.length;)this[this.length]=DateSrc(a[i++])}}if(!Array.prototype.splice){Array.prototype.splice=function(i,c){var j,a=arguments,t=new Array(),r=new Array();i=parseInt(i);c=parseInt(c);if(isNaN(i)||isNaN(c)||i<0||c<0||i+c>this.length)return r;for(j=0;j<i;j++)t[j]=DateSrc(this[j]);for(j=0;j<c;j++)r[j]=DateSrc(this[i+j]);for(j=2;j<a.length;j++)t[t.length]=DateSrc(a[j]);for(j=i+c;j<this.length;j++)t[t.length]=DateSrc(this[j]);this.length=0;for(j=0;j<t.length;j++)this[j]=DateSrc(t[j]);return r}}function rmR(s){var i=0,j=0;while((i=s.indexOf("\r"))!=-1&&j<10000){s=s.substr(0,i)+(i+1<s.length?s.substr(i+1):'');j++}return s};function UA(){var t=this,nv=navigator,n=nv.userAgent.toLowerCase();t.win=n.indexOf('win')>=0;t.mac=n.indexOf('mac')>=0;t.DOM=document.getElementById?true:false;t.dynDOM=document.createElement&&document.addEventListener;t.khtml=nv.vendor=='KDE';var idx=n.indexOf('opera');t.opera=idx!=-1;if(t.opera){t.vers=parseFloat(n.substr(idx+6));t.major=Math.floor(t.vers);t.opera5=t.major==5;t.opera6=t.major==6;t.opera7=t.major==7;t.opera7up=t.vers>=7}t.oldOpera=t.opera5||t.opera6;idx=n.indexOf('msie');if(idx>=0&&!t.opera&&!t.khtml){t.vers=parseFloat(n.substr(idx+5));t.ie3down=t.vers<4;t.ie=t.ie4up=document.all&&document.all.item&&!t.ie3down;t.ie5up=t.ie&&t.DOM;t.ie55up=t.ie&&t.vers>=5.5;t.ie6up=t.ie&&t.vers>=6}t.cm=document.compatMode;t.css1cm=t.cm=='CSS1Compat';t.nn4=nv.appName=="Netscape"&&!t.DOM&&!t.opera;if(t.nn4)t.vers=parseFloat(nv.appVersion);t.moz=t.nn6up=t.gecko=n.indexOf('gecko')!=-1;if(t.gecko)t.vers=parseFloat(n.substr(n.indexOf('rv:')+3));t.nn7up=t.gecko&&t.vers>1;t.hj=n.indexOf('hotjava')!=-1;t.aol=n.indexOf('aol')!=-1;t.aol4up=t.aol&&t.ie4up;t.major=Math.floor(t.vers);t.supp=t.supported=t.oldOpera||t.opera7up||t.ie||t.moz||t.nn4||t.DOM};function Undef(o){return typeof(o)=='undefined'||o===''||o==null};function Def(o){return!Undef(o)};var ua=new UA();function CLSetMY(m,y,f,id){switch(f){case 0:{++m;if(m==12){m=0;y++}break}case 1:{--m;if(m==-1){m=11;y--}break}case 2:{++y;break}case 3:{--y;break}case 4:{break}}var c;if(!window.opener)window.opener=window.parent;if(ua.moz&&ua.vers>=1.4){if(this.opener)c=this.opener.CLcalendar;else c=this.parent.CLcalendar;window.opener=this.parent}else if(window.opener)c=window.opener.CLcalendar;if(c){c[id].date.setFullYear(y);c[id].date.setMonth(m);c[id].created=false}location.reload()};function CLFind(d,f){if(d.getElementById&&Def(d.getElementById(f))){return d.getElementById(f)}else if(ua.ie4up){return d.all[f]}else{if(d.forms.item)for(var i=0;d.forms.item(i)!=null;++i){if(d.forms.item(i).namedItem&&d.forms.item(i).namedItem(f))return d.forms.item(i).namedItem(f);if(d.forms.item(i).elements&&d.forms.item(i).elements[f])return d.forms.item(i).elements[f]}for(var form in d.forms)if(d.forms[form].elements&&d.forms[form].elements[f])return d.forms[form].elements[f]}return null};function GetObjectByFlag(w){t=w.CLcalendar;for(i=0;i<t.length;i++){if(!t[i].created)return t[i]}};function CLAlign(n){return n<10?("0"+n):(""+n);};function CLDateFormat(doc,f,d,m,y){if(doc==null)doc=document;var s=f;d=d<10?("0"+d):d;s=s.replace("dd",d);m++;m=m<10?("0"+m):m;s=s.replace("MM",m);s=s.replace("yyyy",y);s=s.replace("yy",String(y).substr(2));if(CLFind(doc,'time')){var t=CLFind(doc,'time').value;var hours=parseInt(t.substring(0,2)-0);if(hours<0||hours>23){hours=hours%24;hours+=(hours<0?24:0)}s=s.replace("HH",CLAlign(hours));var minutes=parseInt(t.substring(3,5)-0);if(minutes<0||minutes>59){minutes=minutes%60;minutes+=(minutes<0?60:0)}s=s.replace("mm",CLAlign(minutes));var seconds=parseInt(t.substring(6,8)-0);if(seconds<0||seconds>59){seconds=seconds%60;seconds+=(seconds<0?60:0)}s=s.replace("ss",CLAlign(seconds))}return s};function CLClose(c,f,i,ifr,id){var t=window.parent.CLcalendar[id];if(Undef(t))return;var doc;var w=ifr==''?window.opener||window.parent:window.parent||window.opener;if(w&&!i)doc=w.document;else doc=document;var e=CLFind(doc,c);if(Def(e)){var v='',td=new Date();for(j=0;j<t.dates.length;j++){if(t.dates[j]<=td){alert(txt85);return}v+=(j?t.spr:'')+CLDateFormat(null,f,t.dates[j].getDate(),t.dates[j].getMonth(),t.dates[j].getFullYear())}e.value=v;if(e.fireEvent)e.fireEvent("onchange");else{if(e.onchange)e.onchange()}}if(w&&!i){if(Def(w)&&Def(ifr)){var iframe=CLFind(doc,ifr);if(Def(iframe))iframe.style.visibility='hidden';if(ua.opera6){var d=CLFind(doc,"calendar_div");if(Def(d))d.style.visibility='hidden'}}else{window.close()}}};var ctsd=0;function ctsdClear(){clearTimeout(ctsd);ctsd=0};function CLSetDay(c,f,d,m,y,i,ifr,id){if(ctsd){ctsdClear();return}ctsd=setTimeout('ctsdClear()',100);var t=window.parent.CLcalendar[id];if(Undef(t))return;if(t.multi){for(j=0;j<t.dates.length;j++)if(t.dates[j].getFullYear()==y&&t.dates[j].getMonth()==m&&t.dates[j].getDate()==d){t.dates.splice(j,1);return}}var nd=new Date();nd.setFullYear(y);nd.setMonth(m);nd.setDate(d);if(t.multi)t.dates.push(nd);else{for(k=0;k<t.dates.length;k++)for(r=0;r<=t.ptr.mw;r++)for(cl=0;cl<7;cl++){var a=r*7+cl;if(t.ptr.l[a][0]==t.dates[k].getDate()&&t.ptr.l[a][1]==t.dates[k].getMonth()&&t.ptr.l[a][2]==t.dates[k].getFullYear()){var td=CLFind(t.d,'1'+r+cl);var href=CLFind(t.d,'1'+r+cl+'a');var css_class=t.getCssValue(t.ptr.s[a]);if(ua.ie){td.className=css_class;href.className=css_class}else{td.setAttribute("class",css_class);href.setAttribute("class",css_class)}r=t.ptr.mw;break}}t.dates=new Array(nd);t.date.setFullYear(y);t.date.setMonth(m);t.date.setDate(d);CLClose(c,f,i,ifr,id)}};function RegisterObject(obj){var exist_flag=false;if(!window.CLcalendar){window.CLcalendar=new Array();window.CLcalendar[0]=obj;obj.id=0}else{for(i=0;i<window.CLcalendar.length;i++){if(window.CLcalendar[i].id==obj.id)exist_flag=true;break}if(!exist_flag){window.CLcalendar[window.CLcalendar.length]=obj;obj.id=window.CLcalendar.length-1}}};function CLCalendar(def){this.def=def;this.links={};this.styles={};this.hideifr=true;if(Undef(def.txt))this.def.txt=["Previous year","Previous month","Next month","Next year","Apply"];if(Undef(def.multi))this.def.multi=false;if(Undef(def.imgapply))this.def.imgapply='apply.gif';this.spr="\n";this.def.spr="\n";if(Undef(def.wecd_css))this.def.wecd_css=def.cd_css;if(Undef(def.wecw_css))this.def.wecw_css=def.tw_css;if(Undef(def.wdomcw_css))this.def.wdomcw_css=def.tw_css;if(Undef(def.weomcw_css))this.def.weomcw_css=def.tw_css;if(typeof(this.def.img_path)!="undefined"&&this.def.img_path.lastIndexOf("\/")!=this.def.img_path.length-1)this.def.img_path+="/";if(typeof(this.def.template_path)!="undefined"){if(this.def.template_path.lastIndexOf("/")!=this.def.template_path.length-1)this.def.template_path+="/";if(this.def.template_path.indexOf("/")!=0&&typeof(this.def.img_path)!="undefined"&&this.def.img_path.indexOf("/")!=0){var i,t='',a=this.def.template_path.split("/"),l=a.length?a.length-1:0;for(i=0;i<l;i++)t+='../';this.def.img_path=t+this.def.img_path}}};{var CTc=CLCalendar.prototype;CTc.getCss=function(key,d){if(this.getStyle())return "class='"+this.getStyle()+"'";if(!d)d=this.def;if(d[key]){return "class='"+d[key]+"'"}return ""};CTc.getCssValue=function(key,d){if(this.getStyle())return this.getStyle();if(!d)d=this.def;if(d[key]){return d[key]}return ""};CTc.hide=function(){if(window.parent&&this.hideifr&&this.ifr){var iframe=CLFind(window.parent.document,this.ifr);if(iframe)iframe.style.visibility='hidden'}clearEventHandler('keypress');clearEventHandler('keydown')};CTc.create=function(d,ctl){this.created=true;var i=false;if(ctl){this.ctl=ctl;RegisterObject(this);i=true}this.i=i;if(!this.date)this.date=window.date||new Date();if(!this.dates)this.dates=new Array();this.ptr={w:0,d:0,mw:0,l:new Array(),s:new Array()};var def=this.def;var acts='';if(this.ifr&&def.headerstyle.type!="comboboxes"){acts='onMouseOver="window.parent.CLcalendar['+this.id+'].hideifr=false;"';acts+=" onMouseOut=\"window.parent.CLcalendar["+this.id+"].hideifr=true;setTimeout('window.parent.CLcalendar["+this.id+"].hide();',1000);\""}d.write("<table "+(Def(this.ifr)?"align=\"center\"":"")+" cellspacing="+(def.border_width||0)+" cellpadding=0 "+acts+" width="+def.width+" border=0 bgcolor='"+(def.border_color||'#ffffff')+"'>");d.write("<tr>");if(def.headerstyle.type=="buttons")this.createButtons(d);else if(def.headerstyle.type=="comboboxes")this.createCombos(d);d.write("</tr>");var day=0;d.write("<tr>");this.createWeekdays(d);d.write("</tr>");var w=this.createMonth(d);if(def.showtime){this.createTime(d)}if(def.preview){this.createPreview(d)}this.multi=this.def.multi;this.spr=this.def.spr;this.imgapply=this.def.imgapply;if(def.multi){this.createApply(d)}if(ua.opera&&w==4){d.write("<tr><td colspan=7>&nbsp;<td></tr>")}d.write("</table>");this.d=d};CTc.createTime=function(d){time=CLAlign(this.date.getHours())+":"+CLAlign(this.date.getMinutes())+":"+CLAlign(this.date.getSeconds());d.write("<tr><td align=center colspan=7>"+(ua.nn4?"<form>":"")+"<input size="+(String(time).length+3)+" "+(ua.nn4?"name":"id")+"='time' style=\"border:0\" value='"+time+"' "+this.getCss('time_css')+"'>"+(ua.nn4?"</form>":"")+"</td></tr>")};CTc.createPreview=function(d){d.write("<tr><td colspan=7 align=center>"+(ua.nn4?"<form>":"")+"<input size="+(String(this.dtype).length+5)+" id=\"preview_area\""+this.getCss('preview_css')+"style=\"border:0\">"+(ua.nn4?"</form>":"")+"</td>")};CTc.createApply=function(d){d.write("<tr><td colspan=7 align=center>"+"<a href='javascript:CLClose(\""+this.ctl+"\",\""+this.def.dtype+"\","+this.i+",\""+(Def(this.ifr)?this.ifr:"")+"\",\""+this.id+"\")'"+" onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[4]+"\")'><img border=0 src='"+(typeof(this.def.img_path)=="undefined"?'':this.def.img_path)+this.imgapply+"'></a></td></tr>")};CTc.createMonth=function(d){var cd=this.date.getDate();var cm=this.date.getMonth();var cy=this.date.getFullYear();var cday=this.date.getDay();var def=this.def;var cur_day=1;this.date.setDate(cur_day);var thisweek=false;var start=(this.date.getDay()-def.firstday);start+=(start<0?7:0);cur_day-=start;var css,thismonth=false,weekend,thisday,highlight;var w,month;for(w=0;w<6;++w){this.ptr.mw=w;d.write("<tr>");for(var day=0;day<7;++day){weekend=day+def.firstday;weekend-=(weekend<7?0:7);weekend=weekend==0||weekend==6;this.date.setDate(cur_day);if(this.date.getDate()==1){thismonth=!thismonth;if(thismonth)month=this.date.getMonth()}if(day==0){if(w!=0){thisweek=cd-this.date.getDate();if(thisweek<7&&thisweek>=0)thisweek=true;else thisweek=false}else thisweek=(start+cd)<8;if(this.date.getMonth()-month==1)break}if(day==7&&thisweek)thisweek=false;thisday=this.date.getDate()==cd&&thismonth;if(thisday){this.ptr.w=w;this.ptr.d=day}pr_date="'"+this.def.dtype+"',"+this.date.getDate()+","+this.date.getMonth()+","+this.date.getFullYear();highlight=false;if(thismonth){this.tmn=this.date.getMonth();for(i=0;i<this.dates.length;i++)if(this.dates[i].getDate()==this.date.getDate()&&this.dates[i].getMonth()==this.date.getMonth()&&this.dates[i].getFullYear()==this.date.getFullYear()){highlight=true;break}}css=thisday?(weekend?'wecd_css':'cd_css'):(thisweek?(thismonth?(weekend?'wecw_css':'tw_css'):(weekend?'weomcw_css':'wdomcw_css')):(thismonth?(weekend?'we_css':'wd_css'):(weekend?'weom_css':'wdom_css')));span_id='1'+w+day;act='onmouseover="window.parent.CLcalendar['+this.id+'].highlightDate('+w+','+day+');"';d.write("<td align=center width=14% id=\""+span_id+"\" "+act+" "+this.getCss(highlight?'highlight_css':css)+">");d.write("<A "+this.getCss(highlight?'highlight_css':css)+"id=\""+span_id+"a\" "+this.getRef()+">");d.write(this.date.getDate());d.write("</A></td>");this.ptr.l[w*7+day]=[this.date.getDate(),this.date.getMonth(),this.date.getFullYear()];this.ptr.s[w*7+day]=css;cur_day=this.date.getDate()+1}d.write("</tr>");this.date.setDate(cur_day);if((this.date.getDate()<8&&w>3))break}this.date.setFullYear(cy);this.date.setMonth(cm);this.date.setDate(cd);return w};CTc.setLink=function(s,l){this.links[s]=l};CTc.setStyle=function(s,l){this.styles[s]=l};CTc.getStyle=function(){var c;if(this.i){var fd=CLDateFormat(null,this.def.dtype,this.date.getDate(),this.date.getMonth(),this.date.getFullYear());if(this.styles[fd])c=this.styles[fd]}return c};CTc.getRef=function(){var ref;if(this.i){var fd=CLDateFormat(null,this.def.dtype,this.date.getDate(),this.date.getMonth(),this.date.getFullYear());if(this.links[fd])ref=" href='"+this.links[fd]+"'"}ref=ref||(" href='javascript:CLSetDay(\""+this.ctl+"\",\""+this.def.dtype+"\","+this.date.getDate()+","+this.date.getMonth()+","+this.date.getFullYear()+","+this.i+",\""+(Def(this.ifr)?this.ifr:"")+"\",\""+this.id+"\")'");return ref};CTc.createWeekdays=function(d){var def=this.def;var weekend;for(var day=0;day<7;++day){weekend=day+def.firstday;weekend-=(weekend<7?0:7);d.write("<td align=center "+this.getCss("dn_css")+">"+def.daynames[weekend]+"</td>")}};CTc.createButtons=function(d){var dh=this.def.headerstyle;var w=100-(dh.imgprevy?14:0)-(dh.imgprevm?14:0)-(dh.imgnextm?14:0)-(dh.imgnexty?14:0);d.write('<td colspan=7><table width=100% border=0 cellpadding=0 cellspacing=0><tr>');if(typeof(this.def.img_path)!="undefined"){if(dh.imgprevy)d.write("<td width=14% align=left bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",3,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[0]+"\")'><img border=0 src='"+this.def.img_path+dh.imgprevy+"'></a></td>");if(dh.imgprevm)d.write("<td width=14% align=left bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",1,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[1]+"\")'><img border=0 src='"+this.def.img_path+dh.imgprevm+"'></a></td>");d.write("<td width="+w+"% align=center "+this.getCss("css",dh)+">"+this.def.monthnames[this.date.getMonth()]+"&nbsp;"+this.date.getFullYear()+"</td>");if(dh.imgnextm)d.write("<td width=14% align=right bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",0,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[2]+"\")'><img border=0 src='"+this.def.img_path+dh.imgnextm+"'></a></td>");if(dh.imgnexty)d.write("<td width=14% align=right bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",2,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[3]+"\")'><img border=0 src='"+this.def.img_path+dh.imgnexty+"'></a></td>")}else{if(dh.imgprevy)d.write("<td width=14% align=left bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",3,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[0]+"\")'><img border=0 src='"+dh.imgprevy+"'></a>");if(dh.imgprevm)d.write("<td width=14% align=left bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",1,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[1]+"\")'><img border=0 src='"+dh.imgprevm+"'></a>");d.write("<td width="+w+"% align=center "+this.getCss("css",dh)+">"+this.def.monthnames[this.date.getMonth()]+"&nbsp;"+this.date.getFullYear()+"</td>");if(dh.imgnextm)d.write("<td width=14% align=right bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",0,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[2]+"\")'><img border=0 src='"+dh.imgnextm+"'></a></td>");if(dh.imgnexty)d.write("<td width=14% align=right bgcolor=#ffffff><a href='javascript:CLSetMY("+this.date.getMonth()+","+this.date.getFullYear()+",2,"+this.id+")' onmouseover='window.parent.CLcalendar["+this.id+"]."+"setStatus(\""+this.def.txt[3]+"\")'><img border=0 src='"+dh.imgnexty+"'></a></td>")}d.write('<\/tr><\/table><\/td>')};CTc.createCombos=function(d,l){var dh=this.def.headerstyle;d.write('<td colspan=7><table width=100% border=0 cellpadding=0 cellspacing=0><tr>');d.write("<td align=left "+this.getCss("css",dh)+">");if(ua.nn4)d.write("<form>");d.write("<select align=left "+this.getCss("css",dh)+" "+(ua.nn4?"name":"id")+"='month' onchange='CLSetMY(CLFind(document,\"month\").selectedIndex,"+dh.yearrange[0]+"+CLFind(document,\"year\").selectedIndex,4,"+this.id+");'>");var i=0;for(;i<12;++i)d.write("<option "+(i==this.date.getMonth()?"selected='selected'":"")+" value='"+i+"'>"+this.def.monthnames[i]+"</option>");d.write("</select>");d.write("</td><td align=right>");d.write("<select align=right "+this.getCss("css",dh)+" "+(ua.nn4?"name":"id")+"='year' onchange='CLSetMY(CLFind(document,\"month\").selectedIndex,"+dh.yearrange[0]+"+CLFind(document,\"year\").selectedIndex,4,"+this.id+");'>");for(i=dh.yearrange[0];i<=dh.yearrange[1];++i)d.write("<option "+(i==this.date.getFullYear()?"selected='selected'":"")+" value='"+i+"'>"+i+"</option>");d.write("</select>");if(ua.nn4)d.write("</form>");d.write("</td>");d.write('<\/tr><\/table><\/td>')};CTc.parseValue=function(s){var f=this.def.dtype,d=new Date();var t;if(f.indexOf("yyyy")!=-1){t=parseInt(s.substr(f.indexOf("yyyy"),4)-0);if(!isNaN(t)&&typeof(t)!="undefined")d.setFullYear(t)}if(f.indexOf("MM")!=-1){t=parseInt(s.substr(f.indexOf("MM"),2)-1);if(!isNaN(t)&&typeof(t)!='undefined')d.setMonth(t)}if(f.indexOf("dd")!=-1){t=parseInt(s.substr(f.indexOf("dd"),2)-0);if(!isNaN(t)&&typeof(t)!='undefined')d.setDate(t)}if(f.indexOf("HH")!=-1){t=parseInt(s.substr(f.indexOf("HH"),2)-0);if(!isNaN(t)&&typeof(t)!='undefined')d.setHours(t)}if(f.indexOf("mm")!=-1){t=parseInt(s.substr(f.indexOf("mm"),2)-0);if(!isNaN(t)&&typeof(t)!='undefined')d.setMinutes(t)}if(f.indexOf("ss")!=-1){t=parseInt(s.substr(f.indexOf("ss"),2)-0);if(!isNaN(t)&&typeof(t)!='undefined')d.setSeconds(t)}return d};CTc.parseMulti=function(s){if(s=='')return;this.spr=rmR(this.spr);s=rmR(s);var e=s.split(this.spr);this.dates=new Array();for(i=0;i<e.length;i++){this.dates.push(this.parseValue(e[i]))}};CTc.popup=function(ctl){this.created=false;RegisterObject(this);this.ctl=ctl;this.date=new Date();this.parseMulti(CLFind(d,ctl).value);if(typeof(this.def.template_path)!="undefined"){var w=window.open(this.def.template_path+"calendar.php?"+this.id,this.id,'width='+this.def.windoww+',height='+this.def.windowh+',status=no,resizable=no,top=200,left=200,dependent=yes,alwaysRaised=yes')}else var w=window.open("calendar.php?"+this.id,this.id,'width='+this.def.windoww+',height='+this.def.windowh+',status=no,resizable=no,top=200,left=200,dependent=yes,alwaysRaised=yes');w.opener=window;w.focus()};CTc.innerpopup=function(ctl,ifr){RegisterObject(this);this.created=false;this.ctl=ctl;this.ifr=ifr;this.hideifr=false;var e=CLFind(document,ctl);this.date=new Date();this.parseMulti(e.value);var w=CLFind(document,ifr);if(ua.oldOpera){w=document.frames[ifr];w.location.reload();var d=CLFind(document,"calendar_div");d.style.visibility='visible'}else{if(typeof(this.def.template_path)!="undefined"){w.src=this.def.template_path+"calendar.php?"+this.id}else w.src="calendar.php?"+this.id;w.style.visibility='visible'}w.opener=window;w.height=this.def.windowh;w.width=this.def.windoww;if(!ua.moz){w.focus()}};CTc.inline_create=function(d,ctl){if((ua.moz&&ua.vers<1.4)||ua.oldOpera){this.create(d,ctl);return}RegisterObject(this);this.created=false;var pos="relative";var offx=0;var offy=0;if((typeof this.def.position)!="undefined"){if(this.def.position.absolute==true)pos="absolute";else pos="relative";if((typeof this.def.position.y)!="undefined")offy=this.def.position.y;if((typeof this.def.position.x)!="undefined")offx=this.def.position.x}var opacity=100;if((typeof this.def.opacity)!="undefined")opacity=this.def.opacity;this.ctl=ctl;d.write('<iframe id="c_frame'+this.id+'" frameborder="0" name="c_frame"	scrolling="no" STYLE="filter:Alpha(Opacity='+opacity+'); position:'+pos+'; top:'+offy+'; left:'+offx+'; " >');d.write('</iframe>');var e=CLFind(document,ctl);this.date=new Date();this.parseMulti(e.value);var w=CLFind(d,"c_frame"+this.id);if(typeof(this.def.template_path)!="undefined"){w.src=this.def.template_path+"calendar.php?"+this.id}else w.src="calendar.php?"+this.id;w.style.visibility='visible';w.opener=window;w.height=this.def.windowh;w.width=this.def.windoww;if(!ua.moz)w.focus()};CTc.highlightDate=function(w,d){var o=this.ptr.l[this.ptr.w*7+this.ptr.d],m=true;for(j=0;j<this.dates.length;j++)if(o[1]==this.tmn&&this.dates[j].getDate()==o[0]&&this.dates[j].getMonth()==o[1]&&this.dates[j].getFullYear()==o[2]){m=false;break}if(m)this.changeCSS(this.ptr.s[this.ptr.w*7+this.ptr.d]);this.ptr.w=w;this.ptr.d=d;var o=this.ptr.l[w*7+d];this.setStatus(CLDateFormat(this.d,this.def.dtype,o[0],o[1],o[2]));this.changeCSS('highlight_css')};CTc.changeCSS=function(css){var td=CLFind(this.d,'1'+this.ptr.w+this.ptr.d);var href=CLFind(this.d,'1'+this.ptr.w+this.ptr.d+'a');var css_class=this.getCssValue(css);if(ua.ie){td.className=css_class;href.className=css_class}else{td.setAttribute("class",css_class);href.setAttribute("class",css_class)}};CTc.setStatus=function(s){pr=CLFind(this.d,'preview_area');if(pr!=null){pr.size=String(s).length+2;pr.value=s}};function keyNav(id,k,s){var c=window.parent.CLcalendar[id];if(Undef(k))return;if(s)switch(k){case 13:if(!c.multi)return;var o=c.ptr.l[c.ptr.w*7+c.ptr.d];CLClose(c.ctl,c.def.dtype,c.i,(Def(c.ifr)?c.ifr:""),id);return;case 37:var m=c.date.getMonth()-1;if(m==-1){m=11;c.date.setFullYear(c.date.getFullYear()-1)}c.date.setMonth(m);break;case 38:c.date.setFullYear(c.date.getFullYear()+1);break;case 39:var m=1+c.date.getMonth();if(m==12){m=0;c.date.setFullYear(1+c.date.getFullYear())}c.date.setMonth(m);break;case 40:c.date.setFullYear(c.date.getFullYear()-1);break;default:return}else switch(k){case 13:var o=c.ptr.l[c.ptr.w*7+c.ptr.d];CLSetDay(c.ctl,c.def.dtype,o[0],o[1],o[2],c.i,(Def(c.ifr)?c.ifr:""),id);return;case 32:var td=new Date();c.date.setFullYear(td.getFullYear());c.date.setMonth(td.getMonth());c.date.setDate(td.getDate());break;case 37:var cc=c.ptr.w*7+c.ptr.d-1;if(!c.ptr.w&&(cc<0||c.ptr.l[cc+1][1]!=c.ptr.l[cc][1]))keyNav(id,37,true);else c.highlightDate(c.ptr.d==0?c.ptr.w-1:c.ptr.w,c.ptr.d==0?6:c.ptr.d-1);return;case 38:if(!c.ptr.w&&c.ptr.d==6)keyNav(id,39,true);else c.highlightDate(c.ptr.w?c.ptr.w-1:c.ptr.mw,c.ptr.w?c.ptr.d:c.ptr.d+1);return;case 39:var cc=c.ptr.w*7+c.ptr.d+1;if(c.ptr.w&&(cc==c.ptr.l.length||c.ptr.l[cc-1][1]!=c.ptr.l[cc][1]))keyNav(id,39,true);else c.highlightDate(c.ptr.d==6?c.ptr.w+1:c.ptr.w,c.ptr.d==6?0:c.ptr.d+1);return;case 40:if(c.ptr.w==c.ptr.mw&&!c.ptr.d)keyNav(id,37,true);else c.highlightDate(c.ptr.w==c.ptr.mw?0:c.ptr.w+1,c.ptr.w==c.ptr.mw?c.ptr.d-1:c.ptr.d);return;default:return}c.created=false;location.reload()};function regEventHandler(e,h,obj){if(Undef(obj))obj=document;e=e.toLowerCase();if(ua.nn4){var name=e.toUpperCase();obj.captureEvents(Event[name])}var f=typeof(h)=="function"?function(e){var ev=ua.ie?window.event:e;if(Def(ev))ev=new CEvent(ev);return h(ev)}:typeof(h)=="string"?new Function("e","var ev=ua.ie?window.event:e;if (Def(ev)) ev=new CEvent(ev);"+h):null;obj["on"+e]=f};function clearEventHandler(e,obj){if(Undef(obj))obj=document;e=e.toLowerCase();if(ua.nn4){var name=e.toUpperCase();obj.releaseEvents(Event[name])}obj["on"+e]=null};function CEvent(e){var t=this;t._e=e;t.x=ua.nn4||ua.moz?e.pageX:ua.oldOpera?e.clientX:e.clientX+document.body.scrollLeft;t.y=ua.nn4||ua.moz?e.pageY:ua.oldOpera?e.clientY:e.clientY+document.body.scrollTop;t.offsetX=ua.nn4||ua.moz?e.layerX:e.offsetX;t.offsetY=ua.nn4||ua.moz?e.layerY:e.offsetY;t.screenX=e.screenX;t.screenY=e.screenY;t.target=ua.ie?e.srcElement:e.target;t.key=ua.nn4||ua.moz?e.which:e.keyCode;t.alt=ua.nn4?e.modifiers&Event.ALT_MASK:e.altKey;t.ctrl=ua.nn4?e.modifiers&Event.CONTROL_MASK:e.ctrlKey;t.shift=ua.nn4?e.modifiers&Event.SHIFT_MASK:e.shiftKey;t.spec=t.alt||t.ctrl||t.shift;var b=ua.nn4||ua.moz?e.which:e.button;t.b_left=b==1;t.b_mid=ua.nn4||ua.moz?b==2:b==4;t.b_right=ua.nn4||ua.moz?b==3:b==2};function initCalendar(){var w=(Undef(window.opener)||Undef(window.opener.CLcalendar))?window.parent:window.opener;if(ua.oldOpera)window.opener.CLcalendar=w.CLcalendar;window.parent.CLcalendar=w.CLcalendar;var c=GetObjectByFlag(w);if(c){document.write("<div class='clsBody'>");c.create(document);document.write("</div>")}var l=window.location.search;if(l.indexOf('?')==0)l=l.substr(1);regEventHandler('keypress','keyNav("'+l+'",ev.key,ev.spec)');regEventHandler('keydown','keyNav("'+l+'",ev.key,ev.spec)');if(window.focus)window.focus()}}function pw(i,w,h){tryex("winnew('prod_enlarge.php?id="+i+"',"+w+","+h+")");return false};function ac(i){tryex("winnew('cart_add.php?id="+i+"',920,260)");return false};function cSubmit(i){var w=window.opener||window.parent,s=(mc.length?'f':'e')+'.gif';if(und(w)||und(w.document))return;var i=CLFind(w.document,'img'+i);if(und(i))return;i.src='img/cart_'+s;var i=CLFind(w.document,'imgc');if(und(i))return;i.src='img/cart_l'+s;return true};function CLcreate(){if(!und(CLm))return;var params={firstday:lang=='en'?0:1,dtype:lang=='en'?'MM/dd/yyyy':'dd.MM.yyyy',width:275,windoww:300,windowh:200,border_width:0,border_color:'white',dn_css:'clsDayName',cd_css:'clsCurrentDay',tw_css:'clsCurrentWeek',wd_css:'clsWorkDay',we_css:'clsWeekEnd',wdom_css:'clsWorkDayOtherMonth',weom_css:'clsWeekEndOtherMonth',wdomcw_css:'clsWorkDayOthMonthCurWeek',weomcw_css:'clsWeekEndOthMonthCurWeek',wecd_css:'clsWeekEndCurDay',wecw_css:'clsWeekEndCurWeek',preview_css:'clsPreview',highlight_css:'clsHighLight',headerstyle:{type:"buttons",css:'clsDayName',imgnextm:'next.gif',imgprevm:'prev.gif',imgnexty:'next_year.gif',imgprevy:'prev_year.gif'},preview:true,monthnames:lang=='en'?["January","February","March","April","May","June","July","August","September","October","November","December"]:["Январь","Февраль","Март","Апрель","Май","Июнь","Июль","Август","Сентябрь","Октябрь","Ноябрь","Декабрь"],daynames:lang=='en'?["Su","Mo","Tu","We","Th","Fr","Sa"]:["Вс","Пн","Вт","Ср","Чт","Пт","Сб"],txt:lang=='en'?["Previous year","Previous month","Next month","Next year","Apply"]:["Предыдущий год","Предыдущий месяц","Следующий месяц","Следующий год","Применить"],img_path:'img/',template_path:''};CLm=new CLCalendar(params)};function calendar(i){if(!dyn)return;CLm.popup('mcmc_d_'+i);return false};function mcrm(i){if(!confirm(txt52))return false;for(j in mcr)if(mcr[j]==i)return false;for(j in mc)if(mc[j][0]==i){mc.splice(j,1);break}mcr.push(i);mcBuild(0);return false};function chkA(t,m,k,c){var v=parseInt(t.value),i;if(v!=t.value||isNaN(v)||(k&&v<m))t.value=isNaN(v)?m:Math.max(m,v);if(c){v=parseInt(t.value);for(i in clc)d.forms.form1['mcmc_a_'+clc[i]].value=v}chkV()};function chkC(t,c){var v,i;if(c){v=t.value;for(i in clc)d.forms.form1['mcmc_d_'+clc[i]].value=v}};function chkV(){var i,r=0,v,a;for(i in mc){v=d.forms.form1['mcmc_a_'+mc[i][0]].value;a=parseFloat(v*mc[i][4]/mc[i][3]);if(!isNaN(a))r+=a}r/=10000;r=''+r;a=r.indexOf('.');if(a>0){if(lang=='ru')r=r.replace(/\./,',');if(r.length>a+2)r=r.substr(0,a+3)}ge('tv').innerHTML=r};function mcBuild(chk){if(!dyn)return;var r='',i,j,c,k,m,id,f=d.forms.form1,vM,vC,vA,vD,s1,s2;clc=[];for(i in mc){id=mc[i][0];vM=selected_option(f['mcmc_m_'+id],0);vC=selected_option(f['mcmc_c_'+id],0);vA=f['mcmc_a_'+id].value;vD=f['mcmc_d_'+id].value;s1=s2='';m=-1;for(k in mcm)for(j in mc[i][2])if(mcm[k][0]==mc[i][2][j][0]){s1+='<option value='+mcm[k][0]+(vM==mcm[k][0]?' selected':'')+'>'+mcm[k][1]+'</option>';break}for(k in mcc)for(j in mc[i][2])if(vM==mc[i][2][j][0]&&mcc[k][0]==mc[i][2][j][1]){s2+='<option value='+mcc[k][0]+(vC==mcc[k][0]?' selected':'')+'>'+mcc[k][1]+'</option>';if(m<0||vC==mcc[k][0])m=mc[i][2][j][2];break}j=parseInt(i)+1;c=0;if(showAB){if(j==1)c=1;else clc.push(id)}r+='<tr>'+'<th>'+j+'</th>'+'<td>'+mc[i][1]+'</th>'+'<td><select class=ci3 name=mcmc_m_'+id+' size=1 onchange="mcBuild()">'+s1+'</select></td>'+'<td><select class=ci3 name=mcmc_c_'+id+' size=1 onchange="mcBuild()">'+s2+'</select></td>'+'<td><input class=ci3 type=text name=mcmc_a_'+id+' size=10 value="'+Math.max(m,vA)+'" onchange="chkA(this,'+m+',1,'+c+')" onblur="chkA(this,'+m+',1,'+c+')" onkeyup="chkA(this,'+m+',0,'+c+')"></td>'+'<td><table class=ct3 width=100% border=0 cellpadding=0 cellspacing=0>'+'<tr>'+'<th><input class=ci3 type=text name=mcmc_d_'+id+' size=10 value="'+vD+'" onchange="chkC(this,'+c+')" onblur="chkC(this,'+c+')"></th>'+'<td><a href="#" onclick="return calendar(\''+id+'\')"><img src="img/c.gif" width=21 height=21 border=0 alt="'+txt48+'"></a></td>'+'</tr>'+'</table></td>'+'<td><a href=# onclick="return mcrm(\''+id+'\')"><img src="img/x.gif" width=21 height=21 border=0 alt="'+txt49+'"></a></td>'+'</tr>'}for(i in mcr)r+='<input type=hidden name=mcmc_r_'+mcr[i]+' value=1>';if(!chk){ge('mcmc').innerHTML='<table class=ct1 width=100% border=0 cellpadding=0 cellspacing=3>'+'<tr>'+'<th class=ct2>&#8470;</th>'+'<th class=ct2 width=30%>'+txt43+'</th>'+'<th class=ct2 width=25%>'+txt44+'<sup>1</sup></th>'+'<th class=ct2 width=25%>'+txt45+'<sup>2</sup></th>'+'<th class=ct2 width=20%>'+txt46+'<sup>3</sup></th>'+'<th class=ct2>'+txt47+'<sup>4</sup></th>'+'<th class=ct2>&nbsp;</th>'+'</tr>'+r+'<tr>'+'<td colspan=7>'+'<table class=ct4 width=100% border=0 cellpadding=0 cellspacing=0>'+'<tr>'+'<td width=100%>'+txt50+'</td>'+'<th>'+txt78+'&nbsp;<span id=tv></span>&nbsp;'+txt79+'</th>'+(showAB?'<th><input class=ci2 type=submit value="'+txt42+'"></th>':'')+'</tr>'+'</table></td>'+'</tr>'+'</table>';chkV()}};function stch(s){var t=window.status;if(typeof(t)=='undefined')return;ststr=t;window.status=s};function stre(s){if(typeof(window.status)=='undefined')return;window.status=ststr};function ECMsg(c){var e=ge('imgc');if(!und(c)||(!und(e)&&e.src.charAt(e.src.length-5)=='e')){setpos('msg1',Math.max(0,Math.round((winw()-600)/2)),Math.max(0,Math.round((winh()*0.83-140)/2)));setvis('msg1',1);return false}return true};function ECMsgX(){setvis('msg1',0);return false}