This extension module will add route functions to the Maps module. It also does a lot of caching to avoid problems with the limits of the API
You can use it as tags, so you can work with the route data, or you can put it directly as a polyline on the map.
Make sure your system meets the minimum requirements:
This module is using a license field to check if the license for the module is valid or not. On addons.reinos.nl you can check your license and add your valid domains.
In the Module CP you can enter then your license
When you enter a wrong license, the module will not work and it shows you an warning
On a local environment, like *.dev
*.local
*.localhost
*.test
the license will be valid for the testing and building new sites.
Return multi-part directions for a series of waypoints. Directions for several modes of transportation are available.
{exp:maps_services:direction}
Below are the Tag Parameters. Those parameters can be used in the tag described above.
A from address name, can also a name like 'reichenbach im vogtland or amsterdam or america'.
address:from="" [REQUIRED] if latlng:from is empty
latitude longitude coordinates
latlng:from="" [REQUIRED] if address:from is empty
A to address name, can also a name like 'reichenbach im vogtland or amsterdam or america'.
address:to="" [REQUIRED] if latlng:to is empty
latitude longitude coordinates
latlng:to="" [REQUIRED] if address:to is empty
Stops between the from and to point. addresses seperated with a pipline '|'
address:stops="" [OPTIONAL] if latlng:stops is empty
Stops between the from and to point. latitude longitude coordinates seperated with a pipline '|'
latlng:stops="" [OPTIONAL] if address:stops is empty
By default the waypoints are in order how you request it. To have a better and optimized route, you can enable this param so it gives you a better route.
optimize_waypoints="no" [OPTIONAL]
set the travel mode.
values: driving
walking
walking
travel_mode="driving" [OPTIONAL]
values: tolls
highways
ferries
You can use multiple options seperated with a pipline (|)
avoid="tolls" [OPTIONAL]
Set the language based on the language code
lang="en" [OPTIONAL]
Below are the Tag variables. (note the prefix directions:
)
The distance
{direction:distance}
The duration/time
{direction:duration:text}
The start location
{direction:start_location}
The end location
{direction:end_location}
The steps pair tag hold all the steps to on the route
{direction:steps}...{/direction:steps}
The distance
{direction:steps}
{direction:steps:distance}
{/direction:steps}
The duration/time
{direction:steps}
{direction:steps:duration}
{/direction:steps}
The location where the action should take
{direction:steps}
{direction:steps:location}
{/direction:steps}
Formatted HTML instructions of the step
{direction:steps}
{direction:steps:instruction}
{/direction:steps}
The travel mode
{direction:steps}
{direction:steps:travel_mode}
{/direction:steps}
With this tag you can add a route directly to a map. You can use it just like the {map:add_marker}
tag, just put in inside the {exp:maps:map}...{/exp:maps:map}
tag
{maps:add_route}
Below are the Tag Parameters. Those parameters can be used in the tag described above.
A from address name, can also a name like 'reichenbach im vogtland or amsterdam or america'.
address:from="" [REQUIRED] if latlng:from is empty
latitude longitude coordinates
latlng:from="" [REQUIRED] if address:from is empty
A to address name, can also a name like 'reichenbach im vogtland or amsterdam or america'.
address:to="" [REQUIRED] if latlng:to is empty
latitude longitude coordinates
latlng:to="" [REQUIRED] if address:to is empty
stops between the from and to point. addresses seperated with a pipline '|'
address:stops="" [OPTIONAL] if latlng:stops is empty
stops between the from and to point. latitude longitude coordinates seperated with a pipline '|'
latlng:stops="" [OPTIONAL] if address:stops is empty
set the travel mode.
values: driving
transit
walking
travel_mode="driving" [OPTIONAL]
set the stroke color.
stroke:color="#131540" [OPTIONAL]
set the stroke opacity.
stroke:opacity="0.6" [OPTIONAL]
set the stroke weight.
stroke:weight="6" [OPTIONAL]
To fit the routes on the map, the route module add the following tag to the {exp:maps:map}
Fit the map based on the routes
{exp:maps:map
fit_map:routes="no" [OPTIONAL]
}
reinos_
due the release of the EE store (\Breaking changes)***Note: There is a change you will have to validate the license again
\Note:** Because the module has been renamed with a prefix reinos_
there is an update path
by simply add the new update to your site and install it. By installing the module, you are disabling the old module
that can be deleted afterward. Also note that you have to rename the module calls and hooks with a prefix reinos_
See this article about the rename https://addons.reinos.nl/news/modules-renamed