WFS request options

Josh Livni mailing_lists at UMBRELLACONSULTING.COM
Fri Jan 4 11:48:23 EST 2008


Nelson,

Using this method, you don't want to make a WFS request - you want to 
make a WMS request.  The mapserver site has documentation on how to set 
up your mapfile to respond to WMS requests  
(http://mapserver.gis.umn.edu/docs/howto/wms_server) as well as the 
template (which can be very simple for your use case).

There's a thread on the google groups list about using getFeatureInfo, 
but since the guy's WMS is down it's probably not the best example 
(though you could still look at his code).
http://openlayers.org/dev/examples/getfeatureinfo.html is another 
example that you could probably start with for assistance on the client 
side -- you'd need to modify it to work with Google Maps (eg using 
Google's methods to get at their bbox and other criteria while creating 
the queryUrl, and to parse the result) but the concept is the same, so 
this should get you started.

Also - glad to hear my old comments helped on the roadlessland site - it 
looks nice.

Cheers,

 -Josh

PS - Please be sure to CC the mapserver list if this doesn't make sense 
- others here may well have better ideas on how to help than me, and 
chances are if you want to know something, others may be in the same 
boat, and thus find the thread helpful.



nelson guda wrote:
> Hi again, Josh,
>
> I just tried "DescribeFeatureType", which works but the response only 
> give the names of the variables.  Any idea on how to get the actual 
> data about those variables?
>
> many thanks,
> nelson
>
> DescribeFeatureType response:
>
>
>   <element name="ira"
>            type="ms:iraType"
>            substitutionGroup="gml:_Feature" />
>
>   <complexType name="iraType">
>     <complexContent>
>       <extension base="gml:AbstractFeatureType">
>         <sequence>
>           <element name="msGeometry" type="gml:GeometryPropertyType" 
> minOccurs="0" maxOccurs="1"/>
>           <element name="NAME" type="string"/>
>           <element name="ID" type="string"/>
>         </sequence>
>       </extension>
>     </complexContent>
>   </complexType>
>
>
>
>
>
>
> On Jan 4, 2008, at 8:53 AM, Josh Livni wrote:
>
>> This doesn't answer you question exactly, but have you considered 
>> using a WMS getFeatureInfo request instead?  Then you can use a 
>> simple template.html to decide which attributes you want to return 
>> for later parsing.  I've done this a few times myself with Google Maps.
>>
>>  -Josh
>>
>> nelson guda wrote:
>>> Hi all,
>>>
>>> I have an odd request regarding WFS capabilities.  Is it possible to 
>>> have a WFS mapserver request return gml results without the geometry 
>>> data?
>>>
>>> I know that this seems odd, but it makes sense for what I am doing.  
>>> I am using a WMS overlay to serve tiles for a large dataset to an 
>>> overlay on google maps.  In order to query specific polygons from 
>>> that dataset (a shapefile), I am using a WFS GetFeature request.  
>>> All I need is the id and other parameters of the feature, but not 
>>> the geometry data (because it is already there from the WMS.  Right 
>>> now I am just parsing out the info I need from the gml at the server 
>>> level, but it would be much faster if I could get the WFS to return 
>>> only the feature info minus the geometry data.  Is this possible?
>>>
>>> Thanks, and thanks for your previous help.
>>>
>>> nelson



More information about the mapserver-users mailing list