jQuery.cookie=function(name,value,options){if(typeof value!='undefined'){options=options||{};if(value===null){value='';options.expires=-1;}var expires='';if(options.expires&&(typeof options.expires=='number'||options.expires.toUTCString)){var date;if(typeof options.expires=='number'){date=new Date();date.setTime(date.getTime()+(options.expires*24*60*60*1000));}else{date=options.expires;}expires='; expires='+date.toUTCString();}var path=options.path?'; path='+(options.path):'';var domain=options.domain?'; domain='+(options.domain):'';var secure=options.secure?'; secure':'';document.cookie=[name,'=',encodeURIComponent(value),expires,path,domain,secure].join('');}else{var cookieValue=null;if(document.cookie&&document.cookie!=''){var cookies=document.cookie.split(';');for(var i=0;i<cookies.length;i++){var cookie=jQuery.trim(cookies[i]);if(cookie.substring(0,name.length+1)==(name+'=')){cookieValue=decodeURIComponent(cookie.substring(name.length+1));break;}}}return cookieValue;}};var Intro={Lang:'uk',OldIE:false,Text:{Loading:{ru:'Загрузка ядра карты',uk:'Завантаження ядра карти',en:'Loading'},Continue:{ru:'Продолжить работу',uk:'Продовжити роботу',en:'Continue'},Message:{ru:'Для стабильной и быстрой работы карты рекомендуем использовать современные веб-браузеры, такие как <a href="http://www.mozilla-europe.org/ru/firefox/" style="white-space:nowrap">Mozilla Firefox 3</a>, <a href="http://ru.opera.com/" style="white-space:nowrap">Opera 9</a> и <a href="http://www.google.com/chrome/index.html?hl=ru" style="white-space:nowrap">Google Chrome</a>.',uk:'Для стабільної та швидкої роботи карти рекомендуємо використовувати сучасні веб-браузери, такі як <a href="http://www.mozilla-europe.org/uk/firefox/" style="white-space:nowrap">Mozilla Firefox 3</a>, <a href="http://ru.opera.com/" style="white-space:nowrap">Opera 9</a> або <a href="http://www.google.com/chrome/index.html?hl=uk" style="white-space:nowrap">Google Chrome</a>.',en:'For stable work of the map engine we strongly recommend that you use modern web browsers such as <a href="http://www.mozilla-europe.org/en/firefox/" style="white-space:nowrap">Mozilla Firefox 3</a>, <a href="http://www.opera.com/" style="white-space:nowrap">Opera 9</a> and <a href="http://www.google.com/chrome?hl=en" style="white-space:nowrap">Google Chrome</a>.'},IE:{ru:'Ваш браузер, <b>Internet Explorer %version</b>, официально не поддерживается как функционально устаревший.',uk:'Ваш браузер, <b>Internet Explorer %version</b>, офіційно не підтримується як функціонально застарілий.',en:'Your browser, <b>Internet Explorer %version</b>, is not officially supported as functionally obsolete.'},Title:{ru:'Веб-карта Полтавы',uk:'Веб-карта Полтави',en:'Web-map of Poltava'}},DOM:{Loader:null},Load:function(script_src,complete){$.getScript(script_src,function(){$(window).unbind();if(Intro.OldIE){Intro.DOM.Loader.find('input[type=button]').removeAttr('disabled').focus().bind('click',complete);}else{Intro.Complete=complete;setTimeout('Intro.Complete();',300);}});},Locate:function(){var innerHeight=window.innerHeight?window.innerHeight:0;var H=Math.max($(window).height(),innerHeight);var margin=parseInt((H-Intro.DOM.Loader.height())/3.4);margin=margin<0?0:margin;Intro.DOM.Loader.css('margin-top',margin+'px');},IE_Message:function(){if($.browser.msie){var version=parseInt($.browser.version);if(version<7){Intro.OldIE=true;$msg=$(document.createElement('div')).css({'margin':'5px 0px 0px 0px'}).html('<div>'+(Intro.Text.IE[Intro.Lang].replace('%version',version))+'</div><div style="margin:7px 0px 0px 0px;text-align:center"><input id="btnIEBrowser" type="button" value="'+Intro.Text.Continue[Intro.Lang]+'" disabled="disabled" /></div>');return $msg;}}return null;},Create:function(script_src,complete){var lc=$.cookie('lang');if(lc=='ru'||lc=='uk'||lc=='en')Intro.Lang=lc;document.title=Intro.Text.Title[Intro.Lang];Intro.DOM.Loader=$(document.createElement('div')).css({'width':'372px','background-color':'#f0f0f0','margin':'0px auto 0px auto','padding':'3px'}).append($(document.createElement('div')).css({'background-color':'white','border':'1px solid #999999','padding':'5px 8px 5px 8px'}).append($(document.createElement('div')).css({'color':'#999999','text-align':'right'}).append(Intro.Text.Loading[Intro.Lang]),$(document.createElement('div')).css('margin','0px 0px 5px 0px').append($(document.createElement('a')).attr('href','http://navigator.pl.ua').append($(document.createElement('img')).attr('src','http://map.navigator.pl.ua/style/intro-logo.png').attr('alt','Poltava Navigator').attr('height',79).attr('width',348).css({'display':'block','margin':'0px auto 0px auto'}))),$(document.createElement('div')).html(Intro.Text.Message[Intro.Lang]),Intro.IE_Message()));$('body').empty().append(Intro.DOM.Loader);Intro.Locate();$(window).bind('resize',Intro.Locate);Intro.Load(script_src[0],complete);}};