The MapGuide Server I used is local, which works very well. (Version: 2.0.1)

follow is the code I writen with openlayers:

//////////////////////////////
                var params1 = {
                    mapdefinition:
'Library://Archives/Background/Map/BasicMap.MapDefinition'
                }
                var options1 = {
                    isBaseLayer:true,
                    singleTile: true
                }
                var l1 = new OpenLayers.Layer.MapGuide("MapGuide 1",
"http://localhost/mapguide/mapagent/mapagent.fcgi?USERNAME=Anonymous&";,
params1, options1);
                WebMap.addLayer(l1);

                var params2 = {
                    mapdefinition:
'Library://Archives/Projects/Map/PrjMap.MapDefinition',
                    locale: 'en'
                }
                var options2 = {
                    isBaseLayer: false,
                    singleTile: true
                }
                var l2 = new OpenLayers.Layer.MapGuide("MapGuide 2",
"http://localhost/mapguide/mapagent/mapagent.fcgi?USERNAME=Anonymous&";,
params2, options2);
                WebMap.addLayer(l2);

///////////////////////

-- 
View this message in context: 
http://n2.nabble.com/MapGuide-overlayer-can%27t-be-initialized-tp1129544p1130494.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.

_______________________________________________
Users mailing list
[email protected]
http://openlayers.org/mailman/listinfo/users

Reply via email to