<script src="http://api-maps.yandex.ru/1.1/index.xml?key=_здесь_нужен_АПИ_ключ_яндекс_"></script> <script> var map; window.onload = function () { map = new YMaps.Map(document.getElementById("maps")); map.setCenter(new YMaps.GeoPoint(35.01, 48.47), 13); }; function go() { var res, rescont='Адрес для точки ('; var lat=$("#ilat").val(); var lng=$("#ilng").val(); rescont+=lat+', '+lng+') это: '; $.ajax({type: "GET", url: "http://geocode-maps.yandex.ru/1.x/", data:'geocode='+lng+','+lat+'&format=json&kind=house&results=2&key=_здесь_нужен_АПИ_ключ_яндекс_', dataType:"JSON", timeout:30000, async:false, error: function(xhr) { rescont+='Ошибка геокодирования: '+xhr.status+' '+xhr.statusText; }, success: function(html) { res=html; var geores=res.response.GeoObjectCollection.featureMember; if(geores.length>0) { for(k=0;k<geores.length;k++) { rescont+=geores[k].GeoObject.name+'; '; } } else { rescont+='нет данных'; } } }); $('#iout').text(rescont); map.setCenter(new YMaps.GeoPoint(lng,lat)); } </script>