History: Gmap Details
Source of version: 7 (current)
Copy to clipboard
{include page="system~killnotes2016" start="!start killnote GMap" stop="!stop killnote GMap"} ! Google Map Details There are some improvements made to Tiki to take advantage of ((Gmap|Google Maps)). !! Geolocation of Tracker items ''(for Tiki version 1.10)'' Items in a tracker can be geolocated: ::{img src=http://fr.tiki.org/img/wiki_up/fr.tiki.org/googlemap.png }:: !! Panoramio Other similar features (which also Google Maps) could be introduced in your Tiki installation. For instance, Panoramio, a photo-sharing community using Google Maps ("''Discover the world through satellite photos''" - [http://www.panoramio.com]). ::{img src="img/wiki_up/google_map_details_panoramio_01.jpg" }:: This kind of simple feature could included through creating and using those two files in your tiki installation: {CODE(caption=>tiki-panoramio.php,colors=>php)} <?php include 'tiki-setup.php'; $default_lon = '2.338'; $default_lat = '48.89'; $default_zoom = '3'; $default_kind = '2'; if (isset($_REQUEST['lon'])) { $lon = preg_replace('/[^0-9\.-]/','',$_REQUEST['lon']); } else { $lon = $default_lon; } if (isset($_REQUEST['lat'])) { $lat = preg_replace('/[^0-9\.-]/','',$_REQUEST['lat']); } else { $lat = $default_lat; } if (isset($_REQUEST['zoom'])) { $zoom = preg_replace('/[^0-9]/','',$_REQUEST['zoom']); } else { $zoom = $default_zoom; } if (isset($_REQUEST['kind'])) { $kind = preg_replace('/[^0-9]/','',$_REQUEST['kind']); } else { $kind = $default_kind; } $smarty->assign('lon',$lon); $smarty->assign('lat',$lat); $smarty->assign('zoom',$zoom); $smarty->assign('kind',$kind); $smarty->assign('mid','tiki-panoramio.tpl'); $smarty->display('tiki.tpl'); ?> {CODE} {CODE(caption=>templates/tiki-panoramio.tpl)} <form> <input type="text" name="lat" value="{$lat}" size="8" /> <input type="text" name="lon" value="{$lon}" size="8" /> <input type="text" name="zoom" value="{$zoom}" size="2" /> <input type="text" name="kind" value="{$kind}" size="2" /> <input type="submit" name="act" value="{tr}send{/tr}" /> </form> <div>Map is grabbed with panoramio plugin.</div> <iframe src=http://www.panoramio.com/plugin.php?lt={$lat}&ln={$lon}&z={$zoom}&k={$kind} width="100%" height="600px" border="0" style="border:0;"></iframe> {CODE} !! Technical details This implementation uses v2 of the google map API, documented on [http://www.google.com/apis/maps/documentation/reference.html] -=Related pages=- * ((Gmap|Google Maps)) ** ((Gmap User|Google Maps User)) ** ((Gmap Admin|Google Maps Admin)) * [http://www.panoramio.com] * [http://tikiwiki.org/TikiPanoramio]