I’m using Joomla with joomgllery plug-in wich is very popular in Joomla community. This plug-in is helping with creating and managing gallery. There is a feature to view map under image that had in exif info about latitude and longitude. Default is using google maps. I would like to use OSM with mapnik layer. I wrote in joomgallery community to help me. They didn’t know exactly how. They point me a fragment of code, to adapt for OSM.
Here it is:
<div id="jg_geomap">
<script type="text/javascript">
if (GBrowserIsCompatible())
{
var map = new GMap2(document.getElementById('jg_geomap'));
var mapcenter = new GLatLng(<?php echo $this->mapdata; ?>);
map.setCenter(mapcenter, 13);
map.addOverlay(new GMarker(mapcenter));
map.setUIToDefault();
}
else
{
document.write(Joomla.JText._('COM_JOOMGALLERY_DETAIL_MAPS_BROWSER_IS_INCOMPATIBLE'));
}
</script>
</div>
Is there possibility to adapt this code for OSM ?