Yandex maps api plugin for WordPress


Contact form this plugin developer here

For use example remove char ! from [!yandexMap and from [!/yandexMap
Не забудьте удалить знак восклицания (!) из примера.

Example with only place. Click on the map for make a route

[!yandexMap description="Map with route builder" center="55.657793,37.249445" type="map" zoomcontrol="true" typeselector="true" scaleline="true" search="true" geolocation="true" fullscreen="true" traffic="true" showcoords="true" zoom_inital=13 zoom_min=5 zoom_max=16 width="550" height="400"]
[yamap_label coord="55.657793,37.249445" description="Label description" routeonclick="true"
icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico" iconsize="16,16" iconoffset="-8,-8"]
[!/yandexMap]
Map with route builder

Example with multiple places

[!yandexMap center="55.669,37.44" height="300" zoom_inital=12]
[yamap_label coord="55.669051,37.42590" description="Label #1 with image 32x32" icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico" iconsize="32,32" iconoffset="-16,-16"]
[yamap_label coord="55.667,37.447" description="Label #2 with image 16x16" icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/2-tower.ico" iconsize="16,16" iconoffset="-8,-8"]
[yamap_label coord="55.65,37.44790" icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/2-tower.ico"]
[yamap_label coord="55.649071,37.43700" description="Label #3 with image 16x16" icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/3-tower.ico"]
[yamap_label coord="55.663001,37.45" description="Label #4 without image"]
[!/yandexMap]

Example with fill images

[!yandexMap center="55.8180555,37.6138888" zoom_inital=8 zoom_min=5]
[yamap_label coord="55.8180555,37.6138888" description="Ostankino Digital TV broadcaster with service area" icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/3-tower.ico" iconsize="16,16" iconoffset="-8,-8"]
[yamap_fill area="(55.033092,36.15718),(56.54615,39.05099)" description="fill" img="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/msk.png" opacity=0.7]
[!/yandexMap]

Example kml-files load

[!yandexMap description="Load KML" center="55.669,37.44" zoom_inital=2 height="450" minimap="false"]
[yamap_geo url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/raduga.kml"]
[yamap_geo url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/tricolor.kml"]
[!/yandexMap]
Example load KML

Example point, line, circle, polygon, rectangle

[!yandexMap center="55.708111,37.619044" zoom_inital=10]
[yamap_obect type="point" description="1. Point example" coord="55.674756,37.772853"]
[yamap_obect type="line" description="2. Line example 1" coord="(55.874461,37.683589),(55.836612,37.743327)" width="10"]
[yamap_obect type="line" description="3. Line example 2"
width="7" color="#FF00FF" color_opacity="0.5"
coord="(55.900317,37.520167),(55.86674,37.522914),(55.862879,37.575786),(55.896459,37.598445)"]
[yamap_obect type="circle" description="4. Circle Example" coord="(55.665442,37.585399)"
width="7" color="#FF00FF" color_opacity="0.5" fill="#00FF00" fill_opacity="0.3" border_radius="5" radius="5000"]
[yamap_obect type="rectangle" description="5. Rectangle example" coord="(55.70,37.30),(55.80,37.40)"]
[yamap_obect type="polygon" description="6. Polygon example"
width="7" color="#FF00FF" color_opacity="0.5" fill="#00FF00" fill_opacity="0.3" border_radius="5"
coord="((55.75, 37.50),(55.75, 37.71),(55.70, 37.70))"]
[yamap_obect type="polygon" description="7. Complex polygon example"
width="3" color="#FF00FF" color_opacity="0.7" fill="#00FF00" fill_opacity="0.7" border_radius="4"
coord="((55.55, 37.40),(55.55, 37.61),(55.50, 37.60)),((55.53, 37.48),(55.52, 37.60),(55.50, 37.60))"]
[!/yandexMap]

Example with multiple route

[!yandexMap center="55.711335,37.469031" zoom_inital=10]
[yamap_route start="(55.737071,37.520441)" stop="(55.730713,37.446028)" icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/2-tower.ico"]
[yamap_route start="(55.663699,37.482257)" stop="(55.66913,37.447745)" visit="(55.55, 37.40),(55.55, 37.61)" traffic="true"]
[!/yandexMap]

Documentation

Smales example for tag "yandexMap"

[!yandexMap center="55.755768,37.617671"][!/yandexMap]

Full example for tag "yandexMap"

[!yandexMap description="Map caption description" center="55.755768,37.617671" type="satellite" zoomcontrol="true" typeselector="true" scaleline="true" search="true" routeeditor="true" geolocation="true" fullscreen="true" traffic="open" showcoords="true" zoom_inital=13 zoom_min=5 zoom_max=16 width="550" height="400"][!/yandexMap]
Map caption description

yandexMap

url parameter for lang load /?yandex-map-lang=ru_RU

yandex-map-lang parameter must be in list: ru_RU, en_US, en_RU, ru_UA, uk_UA.

Tag [!yandexMap] create map on post. Usually have any number tags [yamap_fill], [yamap_label], [yamap_geo] and [yamap_object]. Tag [!yandexMap] must be in one line. [!yandexMap] propeties:

  • description - caption under the map, text with html tags, default ''
  • center - center coordinates of the map, required value, default '55.755768,37.617671'
  • type - map type, default 'map', allowable values: map, satellite, hybrid, public, publichybrid
  • zoomcontrol - change the map scale control, default true
  • typeselector - select map type control, default true
  • scaleline - scale rule control, default false
  • search - search control, default false
  • routeeditor - route build control, default false
  • geolocation - geolocation control, default false
  • fullscreen - fullscreen control, default false
  • traffic - traffic control, default false, allowable values: open, true
  • showcoords - show coordinates and description of route on map click, default '', allowable values: true
  • zoom_inital, default 13
  • zoom_min, default 0
  • zoom_max, default 17
  • width, default 100%
  • height, default 600px
  • margin_map - map margin, default "10px"
  • margin_desc - description block margin, default "7px"
  • scrollZoom - disable scrollZoom if false, default true
  • drag - disable drag if false, default true
  • dblclickzoom - disable dblclickzoom if false, default true
  • multitouch - disable multitouch if false, default true
  • rightmousebmagnifier - disable rightmousebmagnifier if false, default true
  • leftmousebmagnifier - disable leftmousebmagnifier if false, default true

yamap_label

Tag [yamap_label] create place on map. Value of any propeties must be in one line. There should be no blank lines. [yamap_label] propeties:

  • coord - place coordinates, required value, default '55.755768,37.617671'
  • description, default ''
  • url - body url, default ''
  • header - header text, html, default ''
  • header_url - header url, default ''
  • footer - footer text, html, default ''
  • footer_url - footer url, default ''
  • icon - icon, dotIcon, circleIcon, circleDotIcon or file name, default 'http://api-maps.yandex.ru/i/0.4/icons/house.png'
  • icon_txt - icon text, html, default ''
  • icon_url - icon url, default ''
  • iconcolor - icon color, default #3b5998
  • iconsize, default 16,16
  • iconoffset, default -8,-8
  • routeonclick - make route to this label on map click, default '', allowable values: true

Full [ yamap_label ] tag example:

[yamap_label coord="55.657793,37.249445"
description="(lt)b(gt)WordPress(lt)/b(gt) started in 2003 (lt)img src(equiv)(quot)http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico(quot)(gt)"
routeonclick="true"
url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/"
header_txt="(lt)b(gt)WordPress(lt)/b(gt) started in 2003 (lt)img src(equiv)(quot)http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico(quot)(gt)"
header_url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI"
footer_txt="Patriot, Hanter, Buhanka, Golovastik (lt)img src(equiv)(quot)http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico(quot)(gt)"
footer_url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI"
icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico"
iconsize="16,16"
iconoffset="-8,-8"]

Smalles [ yamap_label ] tag example:

[yamap_label coord="55.755768,37.617671"]

yamap_fill

Tag [yamap_fill] create fill image on map. Value of any propeties must be in one line. There should be no blank lines. [yamap_fill] propeties:

  • area - rectangle coordinates, required value, format: 55.033092,36.15718,56.54615,39.05099, default ''
  • img - file name, required value, default ''
  • opacity, default 0.7

Full [yamap_fill] tag example:

[yamap_fill area="55.033092,36.15718,56.54615,39.05099" img="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/msk.png" opacity=0.8]

Smalles [yamap_fill] tag example:

[yamap_fill area="55.033092,36.15718,56.54615,39.05099" img="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/msk.png"]

yamap_geo

Tag [yamap_geo] load kml on map. Value of any propeties must be in one line. There should be no blank lines. [yamap_geo] propeties:

  • url - kml file url, required value, default ''

[yamap_geo] tag example:

[yamap_geo url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/raduga.kml"]
[yamap_geo url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/tricolor.kml"]

yamap_obect

Tag [yamap_obect] create point, line, circle, polygon or rectangle on map. Value of any propeties must be in one line. [yamap_obect] propeties:

  • type - type of object. Allowable values: "point", "line", "circle", "polygon", "rectangle". Required value. Default 'point'
  • coord - list of coordinates. Required value. Default '55.755768,37.617671'
  • width - line width. Default '3'
  • color - object color. Default '#F008'
  • radius - radius from cycle. Default '1'
  • description - body text and hint, html. Default ''

yamap_route

Tag [yamap_route] create route on map. Value of any propeties must be in one line. [yamap_route] propeties:

  • start - start coordinate. Required value. Format: (55.70,37.30). Default '(55.755768,37.617671)'
  • stop - end coordinate. Required value. Format: (55.70,37.30). Default '(55.752283,37.58351)'
  • visit - visit points. Format: (55.55, 37.40),(55.55, 37.61),(55.50, 37.60). Default ''
  • traffic - avoid traffic jams, Allowable values: "true", "false". Default false
  • icon - file name. Default 'http://api-maps.yandex.ru/i/0.4/icons/house.png'
  • opacity - opacity route on map. Default 1
  • color - route color. Default #885522

Full [yamap_route] tag example:

[!yandexMap center="55.8180555,37.6138888" zoom_inital=8 zoom_min=5]
[yamap_route
icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/2-tower.ico"
traffic = "true"
start="(55.033092,36.15718)"
stop="(56.54615,39.05099)"
visit="(55.55, 37.40),(55.55, 37.61),(55.50, 37.60)"]
[!/yandexMap]

Frequently Asked Questions

Where can I get a Yandex Maps API Key?

No need API Key.

Where can I get latitude and longitude of place?

Use next example and click on the map (use showcoords="true").
[!yandexMap center="55.8180555,37.6138888" showcoords="true"]
[!/yandexMap]

Can insert html into label and map caption?

Click label on next map.

[!yandexMap center="55.657793,37.249445" zoom_inital=12 zoom_min=5 height="300" description="(lt)b(gt)WordPress(lt)/b(gt) started in 2003 (lt)img src(equiv)(quot)http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico(quot)(gt) with a single bit of code to enhance the typography of everyday writing and with fewer users than you can count on your fingers and toes."]
[yamap_label
coord="55.657793,37.249445"
description="(lt)b(gt)WordPress(lt)/b(gt) started in 2003 (lt)img src(equiv)(quot)http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico(quot)(gt)"
url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/"
header_txt="(lt)b(gt)WordPress(lt)/b(gt) started in 2003 (lt)img src(equiv)(quot)http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico(quot)(gt)"
header_url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI"
footer_txt="Patriot, Hanter, Buhanka, Golovastik (lt)img src(equiv)(quot)http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico(quot)(gt)"
footer_url="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI"
icon="http://XN--80AEGCCAES4APFCAKPLI6E.XN--P1AI/images/1-tower.ico"
iconsize="16,16"
iconoffset="-8,-8"]
[!/yandexMap]
WordPress started in 2003 with a single bit of code to enhance the typography of everyday writing and with fewer users than you can count on your fingers and toes.