MapGuide OS with Google Earth

Willem Schwarte willem at
Mon Apr 10 10:37:50 EDT 2006



I have tried your sample for Google Earth, and it work fine with the
sheybogan sample data.


If I paste this in my internet Explorer
<http://localhost/sites/google_earth/water.php>  I will get a bunch of


But when I try to use my own data I get an error:


PHP Fatal error: Uncaught exception 'mgobjectnotfoundexception' in
Unknown on line 0


In the water.php file I change this line like so:


$featureReader = $featureService->SelectFeatures(new
FeatureSource"), "totaal_tvg32010101_v", null);


As you can see in XML below, this does exist.  Do you might know why I
don't get anything ?












1##>  <ResourceDocumentHeader

1##>  <General>



1##>  <Security


1##>  <Groups>

1##>  <Group>











Van: Jason Birch [mailto:Jason.Birch at] 
Verzonden: dinsdag 14 maart 2006 8:19
Aan: users at
Onderwerp: MapGuide OS with Google Earth


I've uploaded a pretty basic example of using MapGuide OS to serve KML
to Google Earth, based on an example that Bob Bray provided with the
first preview:


This is totally unsupported, but in my experience it works with the
Sheboygan data set.  On a standard Windows/Apache/Php install you should
just have to follow the instructions in the readme.txt file.


I had a better example that worked to return data for the current
bounding box (you can see it in action at ) but
I was unable to get this working with the sample data, so either
something has changed with 1.0 or the sample data is different somehow
than what I'm serving.  I didn't get any error messages, but seeing all
of the exception codes in the API, I guess I should be trapping for
these somehow.  Not enough time to research now though.


My to-do list:

- clean up the code, make it more modular, and possibly use TJ's
KMLDocument class for generating the KML:

- figure out how to read the default scale ranges and symbology from
MapGuide, and return a semblance of those instead of having to custom
code each layer.  

- dynamically rewrite the bounding box, so that it shifts to the
foreground when the view is tilted, allowing delivery of data without
killing the server with a huge extent

- deliver GroundOverlay images as an option for small-scale mapping
where serving vectors is inappropriate


Of course Autodesk could just step in any time now and provide a
template for default delivery of KML :)




-------------- next part --------------
An HTML attachment was scrubbed...

More information about the Mapguide-users mailing list