You are here

function getdirections_locations_via_path in Get Directions 6.2

Same name and namespace in other branches
  1. 6 getdirections.api.inc \getdirections_locations_via_path()
  2. 7.3 getdirections.api.inc \getdirections_locations_via_path()
  3. 7.2 getdirections.api.inc \getdirections_locations_via_path()

API Function to generate a url path for use by other modules/themes.

Example Usage: $nids = "1,2,3,4"; where '1' is the nid of the starting point '4' is the nid of the end point and the numbers in between are the nids of the waypoints $path = getdirections_locations_via_path($nids); $url = l(t('Get directions'), $path);

Parameters

string $nids: Required. A comma delimited list of nid numbers

Return value

Returns a path relative to the drupal root.

File

./getdirections.api.inc, line 126
Get directions API

Code

function getdirections_locations_via_path($nids) {
  if (module_exists('location')) {
    return "getdirections/locations_via/{$nids}";
  }
}