gml:featureMember with more than one geometry

Christoph Ratke ratke at geoinformationsdienst.de
Tue Mar 7 04:19:45 EST 2006


Hi list,
when I made a Gazetteer request on geometries with "islands" (that is a 
gml:featureMember element with  ) I did not get the whole geometry but 
only the last one. I am requesting a UMN Mapserver WFS (but I once 
encountered the same with a Geoserver WFS). Finally I moved a counter in 
another if condidtion in the parsegml function in classes/class_gml2.php.

I am not sure if this is a general problem or only a specific solution. 
Could you please check it out once you got time (and maybe appropriate 
geometries)? See the code snippet below:

// classes/class_gml2.php - parsegml($req):
changed
-- snip ---
else if(strtoupper($element[tag]) == strtoupper("gml:coordinates") && 
$geom == true){
                    $this->geometry[$this->member][$cnt_geom] =  
str_replace(",,","",str_replace(" ",",",trim($element[value])));
               }
                else 
if(in_array($this->sepNameSpace($element[tag]),$this->geometries) && 
$element[type] == "close"){
                    $cnt_geom++;
                    $geom = false;
--- snap ---

to
--- snip ---
else if(strtoupper($element[tag]) == strtoupper("gml:coordinates") && 
$geom == true){
                    $this->geometry[$this->member][$cnt_geom] =  
str_replace(",,","",str_replace(" ",",",trim($element[value])));
                   $cnt_geom++;
                }
                else 
if(in_array($this->sepNameSpace($element[tag]),$this->geometries) && 
$element[type] == "close"){
                    //$cnt_geom++;
                    $geom = false;
--- snap ---

regards
Christoph

-- 
Christoph Ratke
GeoInformationsDienst GmbH
Götzenbreite 10
37124 Rosdorf
Fon:    ++49-(0)551-7890-25
eMail:  ratke at geoinformationsdienst.de
Web:    www.geoinformationsdienst.de





More information about the Mapbender_dev mailing list