Reply To: KMLin custom php map

Home Forums MapPress Support KMLin custom php map Reply To: KMLin custom php map

#10936
tbecker
Participant

I have gotten a custom map working and the type value seemed like the piece I was missing, but I still haven’t gotten it to work. I’ve put this example together with the example in the documentation and still no luck.

This is what I’m testing right now:

[code]

$mymap = new Mappress_Map(array(“width” => “100%”));
$mypoi_1= new Mappress_Poi(array(“iconid” => “green-dot”, “title” => “KML Example”, “type” => “kml”, “kml” => “http://kml-samples.googlecode.com/svn/trunk/kml/Region/polygon-min-max.kml”));
$mypoi_2 = new Mappress_Poi(array(“title” => “500 Chestnut St”, “body” => “Independence National Park, Philadelphia, PA<br/>19106”, “point” => array(“lat” => 39.948712,”lng” => -75.15001)));
$mymap->pois = array($mypoi_1, $mypoi_2);
echo $mymap->display(array(“directions”=>”none”));

[/code]

It shows the point, but not the kml file. The kml file does display in the shortcode mashup.

By the way, how do you format code in a post?