Support Centre

How do I open maps from my own website?

Last Updated: Jan 05, 2017 10:38AM EST

The Avenza Maps app supports a custom URL scheme that let's you automatically open maps in Avenza Maps from your own web pages or applications. To automatically load a map into Avenza Maps from your own web page, add a link like this:
Code:

<a href="avenzamaps://www.yoursite.com/path/to/map.pdf">Click Here To Open in Avenza Maps</a>

The scheme works the same as a regular "http" link, just replace "http" with "avenzamaps". The "avenzamaps" scheme also supports several parameters for configuring how the map will appear and render inside Avenza Maps.


Parameters:

"title" allows you to set the initial title for the map.  For example, the following will create a new map with the title "My New Map" (notice that the space character " " is encoded as %20 in urls).  If no title is specified Avenza Maps uses the name of the file itself for the map title.
Code:


avenzamaps://www.yoursite.com/path/to/map.pdf?title=My%20New%20Map



"maxZoom" allows you to set the maximum zoom for the map in the Avenza Maps viewer.  For example, the following will limit the Avenza Maps app to a maximum of 300% zoom when viewing the map.  This setting is useful for maps that don't have tiles created for higher zooms or do not look good a high zoom.  The default maximum zoom is 800%.
Code:


avenzamaps://www.yoursite.com/path/to/map.pdf?maxZoom=300



"tileDepth" controls what scales Avenza Maps will generate tiles for when first processing a map.  By default Avenza Maps creates tiles at four scales 50%, 100%, 200% and 400%.  When zooming in and out of the map the tiles from the appropriate scale are shown to the end user. This can be changed to process fewer scales to save time initially processing a map. For example, the following will instruct Avenza Maps to only create tiles at 50% and 100% scales.
Code: 


avenzamaps://www.yoursite.com/path/to/map.pdf?tileDepth=2



"renderingStrategy" gives the Avenza Maps app hints as to how to manage memory when initially processing the map file.  Example:
Code:


avenzamaps://www.yoursite.com/path/to/map.pdf?renderingStrategy=2

Valid values are:

0 - "Device" - Use amount of memory on device to choose strategy.
1 - "Conservative" - Use memory as conservatively as possible when processing the map.
2 - "Aggressive" - Favour speed over memory concerns when processing the maps.

Note: setting an Aggressive strategy may cause Avenza Maps to shut down during processing if too much memory is used.

Use example:

Parameters can be combined.  For example, for a map that only composed of a raster image that fills the entire document it's not needed to create tiles for scales > 100% as no new detail will be revealed.  Also, zooming in on the raster too far will make it appear very blurry. So you might want to set the rendering settings like this:
Code:

avenzamaps://www.yoursite.com/path/to/raster_map.pdf?tileDepth=2&maxZoom=300

470780163d9e7375078734b8b53cc574@avenza.desk-mail.com
http://assets1.desk.com/
false
desk
Loading
seconds ago
a minute ago
minutes ago
an hour ago
hours ago
a day ago
days ago
about
false
Invalid characters found
/customer/en/portal/articles/autocomplete