You can use Google Maps API, but be aware, you will have an 8 waypoint limit between start and finish:
$(document).ready(function () {
getLocation();
showRoute();
});
function getLocation() {
showPosition();
}
var directionsDisplay;
var directionsService = new google.maps.DirectionsService();
var map;
function showPosition() {
var mapcanvas = document.getElementById('map');
directionsDisplay = new google.maps.DirectionsRenderer();
var coords = new google.maps.LatLng(-29.1210600
, 26.2140000);
var options = {
zoom: 6,
center: coords,
mapTypeControl: false,
navigationControlOptions: {
style: google.maps.NavigationControlStyle.SMALL
},
mapTypeId: google.maps.MapTypeId.ROADMAP
};
map = new google.maps.Map(mapcanvas, options);
directionsDisplay.setMap(map);
}
function showRoute() {
var start = 'Cape Town, WC, ZA';
var end = 'Pretoria, GP, ZA';
var waypnts = [];
waypnts.push({
location:'Worcester, WC, ZA',
});
waypnts.push({
location: 'Beaufort West, WC, ZA',
});
waypnts.push({
location: 'Three Sisters, NC, ZA',
});
waypnts.push({
location: 'De Aar, NC, ZA',
});
waypnts.push({
location: 'Oranjerivier, NC, ZA',
});
waypnts.push({
location: 'Kimberley, NC, ZA',
});
waypnts.push({
location: 'Warrenton, NC, ZA',
});
waypnts.push({
location: 'Bloemhof, NW, ZA',
});
var request = {
origin: start,
destination: end,
waypoints: waypnts,
optimizeWaypoints: true,
travelMode: google.maps.TravelMode.DRIVING
};
directionsService.route(request, function (response, status) {
if (status == google.maps.DirectionsStatus.OK) {
directionsDisplay.setDirections(response);
}
});
}