function getdirections_latlon in Get Directions 6.2
Same name and namespace in other branches
- 7.3 getdirections.module \getdirections_latlon()
- 7.2 getdirections.module \getdirections_latlon()
Function to setup the map and form
Parameters
string $direction: Required. The direction the supplied input applies to
string $latlon: Required. A latitude,longitude pair
string $locs: Optional. a description of the target.
Return value
Returns the themed map and form
1 call to getdirections_latlon()
1 string reference to 'getdirections_latlon'
- getdirections_menu in ./
getdirections.module - Implementation of hook_menu().
File
- ./
getdirections.module, line 1132 - Fetches google map directions.
Code
function getdirections_latlon($direction, $latlon, $locs = '', $width = '', $height = '') {
$country = '';
$nid = 0;
$type = 'other';
if (!getdirections_latlon_check($latlon)) {
watchdog('getdirections', 'Lat, Lon failed for user id !uid', array(
'!uid' => $uid,
), WATCHDOG_WARNING);
$latlon = getdirections_load_latlon_defaults();
}
$content = getdirections_direction($direction, $locs, $country, $latlon, $nid, $type, $width, $height);
return $content;
}