Answer the question
In order to leave comments, you need to log in
How to make a link from one page to another page with a specific yandex map tag?
Good afternoon!
I have store addresses on one page
. On the other page, a Yandex map with tags
. Is it possible to make a link from an address to a specific link?
ymaps.ready(function () {
var myMap = new ymaps.Map('map', {
center: [47.228332,39.714797],
zoom: 14
}, {
searchControlProvider: 'yandex#search'
}),
// Создаём макет содержимого.
MyIconContentLayout = ymaps.templateLayoutFactory.createClass(
'<div style="color: #FFFFFF; font-weight: bold;">$[properties.iconContent]</div>'
),
myPlacemark1 = new ymaps.Placemark([47.226417,39.722424],{
hintContent: 'г. Ростов-на-Дону, ул. Чехова 53',
balloonContent: 'г. Ростов-на-Дону, ул. Чехова 53'
}, {
iconLayout: 'default#imageWithContent',
iconImageHref: 'http://dev01my7.beget.tech/img/loc.png',
iconImageSize: [30, 42],
iconImageOffset: [0, 0],
}),
myPlacemark2 = new ymaps.Placemark([47.226692,39.717196], {
hintContent: 'г. Ростов-на-Дону, проспект Ворошиловский 36',
balloonContent: 'г. Ростов-на-Дону, проспект Ворошиловский 36'}, {
iconLayout: 'default#imageWithContent',
iconImageHref: 'http://dev01my7.beget.tech/img/loc.png',
iconImageSize: [30, 42],
iconImageOffset: [0, 0]
});
myMap.geoObjects
.add(myPlacemark1)
.add(myPlacemark2);
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question