[mapserver-users] WMS raster display, getfeatureinfo from vectorlayer

percy percyd at pdx.edu
Fri Jul 11 18:12:17 EDT 2008


Bruce, thanks for the suggestion. That might work, and I might try it at
some point, but I need this to work across all clients, and what I've
noticed is that even if have layers named the same thing, each instance
shows up in the list of available layers to the client.

Then if the user selects the unobtrusive layer to turn on, they won't
see anything, and if they choose the one that has the raster, it won't
be queryable!

I think either the WxS wrapper or a mod_rewrite are my two potential
short term solutions. I'd be delighted to hear otherwise :-)
Cheers,
Percy

Bruce Cheney wrote:
> Just a couple of thoughts - shouldn't your type be Polygon if you are
> referring to your polygon shapefile? Then make the symbology for this
> layer nonintrusive (so the users don't see it).  I believe your query
> will reference the NAME item to obtain specific feature information.
> 
> LAYER
>   	NAME QUERYLAYER
> 	DATA yourshapefilename
> 	TYPE POLYGON
> 	STATUS ON
> 
> 	CLASS
>   		Define symbology - one symbol for entire layer
> 	END
> 
> 	TEMPLATE "x"
> END
> 
> 
> Bruce Cheney
> 
> -----Original Message-----
> From: mapserver-users-bounces at lists.osgeo.org
> [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of percy
> Sent: Thursday, July 10, 2008 5:43 PM
> To: Steve Lime
> Cc: mapserver
> Subject: Re: [mapserver-users] WMS raster display,getfeatureinfo from
> vectorlayer
> 
> thanks, nice idea. I tried it, and that did not work...
> 
> relevant mapfile section:
> 
> LAYER
> 	NAME "Geologic_Map_Of_North_America"
> 	TYPE RASTER
> 	STATUS ON
> 	data "/vol/www/ngmdb/htdocs/GMNA_INDEX_tiled.tif"
> 	maxscale 10000000
> 	MINSCALE 500000
> Metadata
> "WMS_TITLE" "Geologic Map Of North America"
> "WMS_SRS" "epsg:4326"
> END # metadata
> END #layer
> LAYER
> 	NAME "Geologic_Map_Of_North_America"
> 	TYPE query
> 	STATUS On
> 	data GMNA_S_OneGeo
> 	TOLERANCE 0
> 	TOLERANCEUNITS pixels
> 	TRANSFORM TRUE
> 	DUMP TRUE
> 	HEADER "templates/GMNA_query_header.html"
> 	TEMPLATE "templates/GMNA_query_body.html"
> 	FOOTER "templates/GMNA_query_footer.html"
> Metadata
> "WMS_TITLE" "Geologic Map Of North America"
> "WMS_SRS" "epsg:4326"
> GML_INCLUDE_ITEMS
> "DisplayNam,OneGeology,Lithologic,GeologicAg,AgeMin,AgeMax,AgeMetadat"
> WMS_INCLUDE_ITEMS
> "DisplayNam,OneGeology,Lithologic,GeologicAg,AgeMin,AgeMax,AgeMetadat"
> END # metadata
> END #layer
> 
> 
> Steve Lime wrote:
>> What about using GROUPs or layers with the same name where the second 
>> layer is TYPE QUERY?
>>
>> Steve
>>
>>>>> On 7/10/2008 at 2:14 PM, in message <48765F96.20209 at pdx.edu>, percy
>> <percyd at pdx.edu> wrote:
>>> I discussed this issue with Tom K. on the IRC yesterday, and he 
>>> thought it was of general interest and should be posted and 
>>> potentially requested as a feature.
>>>
>>> Scenario: we have a Geologic map that has super complex cartography 
>>> that we don't want to reproduce in the mapfile (600+ classes, tons of
> 
>>> patterns, etc). So we dumped out a raster of it to serve as WMS.
>>>
>>> However, when the user does a GetFeatureInfo on this WMS, we want to 
>>> return attribute data from the original shapefile.
>>>
>>> I can envision this being taken care of at the layer level as a 
>>> metadata tag like "WMS_query_redirect".
>>>
>>> In the short term we're working on a little apache mod_rewrite magic 
>>> to take care of it :-)
>>>
>>> Cheers,
>>> Percy
>>
> 
> --
> David Percy
> Geospatial Data Manager
> Geology Department
> Portland State University
> http://gisgeek.pdx.edu
> 503-725-3373
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
> 

-- 
David Percy
Geospatial Data Manager
Geology Department
Portland State University
http://gisgeek.pdx.edu
503-725-3373



More information about the mapserver-users mailing list