I using two user defined tags
First tag holds java script include which should stay in header.
the code is
Code: Select all
/**
* Showing 1 point with Phoogle Maps
* class developed by Justin Johnson <justinjohnson@system7designs.com>
*/
if($_GET[page] == 'map'){
require_once 'plugins/phoogle/phoogle.php';
global $map;
$map = new PhoogleMap();
$map->setAPIKey("ABQIAAAALs5pheQFCZ8HwyJ8gRD_YRSdwRFzTB9UbL5b0H6xdF2yKOjZoRS4HpGIiwRcbmb_YtHxrxFLPfZDvQ");
$map->printGoogleJS();
}
Code: Select all
global $map;
$map->addGeoPoint('42.770352', '23.320885', 'Sofia, Bulgaria');
$map->addGeoPoint('43.027741', '25.103416', 'Sevlievo, Bulgaria');
$map->addGeoPoint('42.992343', '25.039215', 'Sennik Bulgaria');
$map->addAddress('Sevlievo, Bulgaria', 'Sevlievo');
$map->centerMap('42.992343', '25.039215');
$map->showMap();
You can see the methods in the class and there is an example how to do this with easy.