Saving a map

newjim j_oleary_ed at yahoo.ca
Mon Jul 10 20:08:55 EDT 2006


I am working with the change_layers_via_dom.php example, and want to save the
new layer and modified map. But I get an XML parser exception when I try to
save the map. The relevant lines are:

$resourceService =
$siteConnection->CreateService(MgServiceType::ResourceService);

  
    // --------------------------------------------------//
    // Open the map
    $map = new MgMap();
    $map->Open($resourceService, "Sheboygan");
   .
   .
/* I am able to use SetResource to save a new layer into the library and see
it in the Studio IDE. Next, i want to save the map with the new layer on it.
*/
$repositoryName="Library://Samples/Sheboygan/Maps/Sheboygan.MapDefinition";
$repositoryID = new MgResourceIdentifier($repositoryName);
$repositoryID->Validate();
// At the line below I get a parser exception
$map->Save($resourceService,$repositoryID);

Any suggestions? 

Thanks
-- 
View this message in context: http://www.nabble.com/Saving-a-map-tf1921704.html#a5261596
Sent from the OSGeo MapGuide forum at Nabble.com.





More information about the Mapguide_users mailing list